ARS-Simple

 view release on metacpan or  search on metacpan

html/Simple.html  view on Meta::CPAN


<p>Query a form and get the data back as a hash reference where the keys are the Entry-Id&#39;s for the records matched by the query and the value is a hash reference to the fields you requested where the keys are the field names you used and the val...

<pre><code> <span class="keyword">my</span> <span class="variable">$form</span>  <span class="operator">=</span> <span class="string">'form'</span><span class="operator">;</span>
 <span class="keyword">my</span> <span class="variable">$query</span> <span class="operator">=</span> <span class="string">qq('FID' = "value")</span><span class="operator">;</span>
 <span class="keyword">my</span> <span class="variable">$data</span> <span class="operator">=</span> <span class="variable">$ar</span><span class="operator">-&gt;</span><span class="variable">get_data_by_label</span><span class="operator">(</span><sp...
     <span class="string">form</span>  <span class="operator">=&gt;</span> <span class="variable">$form</span><span class="operator">,</span>
     <span class="string">query</span> <span class="operator">=&gt;</span> <span class="variable">$query</span><span class="operator">,</span>
     <span class="string">lfid</span>  <span class="operator">=&gt;</span> <span class="operator">{</span> <span class="variable">label1</span><span class="operator">,</span> <span class="variable">fid1</span><span class="operator">,</span> <span cla...
     <span class="operator">}</span><span class="operator">);</span>
 
 <span class="variable">$data</span> <span class="operator">=</span> <span class="operator">{</span>
     <span class="variable">eID1</span><span class="operator">,</span> <span class="operator">{</span><span class="string">Label1</span> <span class="operator">=&gt;</span> <span class="variable">value1</span><span class="operator">,</span> <span cla...
     <span class="variable">eID2</span><span class="operator">,</span> <span class="operator">{</span><span class="string">Label1</span> <span class="operator">=&gt;</span> <span class="variable">value1</span><span class="operator">,</span> <span cla...
     <span class="operator">...</span>
     <span class="operator">}</span><span class="operator">;</span>
</code></pre>

<h2 id="get_fields">get_fields</h2>

<p>get_fields has a required argument, the form you require the field details for. The returned hash reference is the result of a call to ars_GetFieldTable, the keys are the field names and the values are the field ids (fid).</p>

<h2 id="set_max_entries">set_max_entries</h2>

<p>This requires that the &#39;user&#39; has administrator access. This allows the overriding of the <b>system wide</b> maximum rows returned setting AR_SERVER_INFO_MAX_ENTRIES, setting this to zero (0) will allow unlimited returns.</p>

<p><b>Beware of setting this to a small value, it is system wide and could have a major impact on your system</b></p>

<h1 id="PRIVATE-METHODS">PRIVATE METHODS</h1>

<h2 id="init">_init</h2>

<p>Initialisation for new</p>

<h2 id="load_qualifier">_load_qualifier</h2>

<h2 id="DESTROY">DESTROY</h2>

<p>Log out from ARSystem</p>

<h2 id="check_initialised">_check_initialised</h2>

<p>Check to insure that there is a connection to Remedy ARSystem. Returns true if connected.</p>

<h2 id="reset_max_entries">_reset_max_entries</h2>

<p>If set, returns the the system wide AR_SERVER_INFO_MAX_ENTRIES back to a suitable value (eg 3000). This required the &#39;user&#39; has administrator access</p>

<h1 id="TODO">TODO</h1>

<p>Add in the tools below.</p>

<p>Add in further methods to make life easier and your code more readable</p>

<h1 id="TOOLS">TOOLS</h1>

<p><b>NOT DONE YET</b></p>

<p>The lfid array used by the get_data_by_label() method required that a hash is defined which describes the field lables (names) you want to use mapped to the field ID (FID). The encluded script will construct such a hash for all relavent fields. Yo...

<p>There is a win32 version of this which copies the data to your clipboard, to make your life easier.</p>

<h1 id="AUTHOR">AUTHOR</h1>

<p>Greg George, <code>&lt;gng at cpan.org&gt;</code></p>

<h1 id="BUGS">BUGS</h1>

<p>Please report any bugs or feature requests to <code>bug-ars-simple at rt.cpan.org</code>, or through the web interface at <a href="http://rt.cpan.org/NoAuth/ReportBug.html?Queue=ARS-Simple">http://rt.cpan.org/NoAuth/ReportBug.html?Queue=ARS-Simple...

<h1 id="SUPPORT">SUPPORT</h1>

<p>You can find documentation for this module with the perldoc command.</p>

<pre><code>    perldoc ARS::Simple</code></pre>

<p>You can also look for information at:</p>

<ul>

<li><p>RT: CPAN&#39;s request tracker (report bugs here)</p>

<p><a href="http://rt.cpan.org/NoAuth/Bugs.html?Dist=ARS-Simple">http://rt.cpan.org/NoAuth/Bugs.html?Dist=ARS-Simple</a></p>

</li>
<li><p>AnnoCPAN: Annotated CPAN documentation</p>

<p><a href="http://annocpan.org/dist/ARS-Simple">http://annocpan.org/dist/ARS-Simple</a></p>

</li>
<li><p>CPAN Ratings</p>

<p><a href="http://cpanratings.perl.org/d/ARS-Simple">http://cpanratings.perl.org/d/ARS-Simple</a></p>

</li>
<li><p>Search CPAN</p>

<p><a href="http://search.cpan.org/dist/ARS-Simple/">http://search.cpan.org/dist/ARS-Simple/</a></p>

</li>
</ul>

<h1 id="ACKNOWLEDGEMENTS">ACKNOWLEDGEMENTS</h1>

<p>This module relies on the ARSperl module and the fantastic effort by Jeff.C.Murphy and J.W.Murphy to write keep ARSperl current over so many years.</p>

<pre><code> See http://arsperl.sourceforge.net/ for more details.
 and https://metacpan.org/release/ARSperl</code></pre>

<p>Remedy Corporation (long since gone) for making the ARSystem C API available thereby allowing ARSperl and this module possible</p>

<h1 id="LICENSE-AND-COPYRIGHT">LICENSE AND COPYRIGHT</h1>

<p>Copyright 2013 Greg George.</p>

<p>This program is free software; you can redistribute it and/or modify it under the terms of the the Artistic License (2.0). You may obtain a copy of the full license at:</p>

<p><a href="http://www.perlfoundation.org/artistic_license_2_0">http://www.perlfoundation.org/artistic_license_2_0</a></p>

<p>Any use, modification, and distribution of the Standard or Modified Versions is governed by this Artistic License. By using, modifying or distributing the Package, you accept this license. Do not use, modify, or distribute the Package, if you do n...



( run in 0.550 second using v1.01-cache-2.11-cpan-df04353d9ac )