<html><head><meta http-equiv="Content-Type" content="text/html charset=utf-8"></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">Thanks Barton!<div class=""><br class=""></div><div class="">That wasn’t exactly what I wanted but it helped me figure it out! btw I had to capitalize Dumper in “print Dumper $client;” for it to work. But seeing everything that came out of the “dumper” let me know the innards of the RT::CustomFieldValue.</div><div class=""><br class=""></div><div class="">The code I ended up using:</div><div class=""><br class=""></div><div class=""><div dir="ltr" class=""><div class=""><div class=""><font face="monospace, monospace" class="">my $clientcustomfield = RT::CustomFieldValues->new($RT::SystemUser);</font></div><div class=""><font face="monospace, monospace" class="">$clientcustomfield->LimitToCustomField(45);</font></div><div class=""><font face="monospace, monospace" class=""><br class=""></font></div><div class=""><font face="monospace, monospace" class="">my $clients = $clientcustomfield;</font></div><div class=""><font face="monospace, monospace" class=""><br class=""></font></div><div class=""><font face="monospace, monospace" class="">while (my $client = $clients->Next ) {</font></div><div class=""><font face="monospace, monospace" class="">        <b class="">print $client->Name;</b></font></div><div class=""><font face="monospace, monospace" class="">        print "\n";</font></div><div class=""><font face="monospace, monospace" class="">}</font></div></div></div></div><div class=""><br class=""></div><div class=""><div apple-content-edited="true" class="">
<div style="color: rgb(0, 0, 0); letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div style="color: rgb(0, 0, 0); letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class=""><div style="color: rgb(0, 0, 0); letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">—</div><div style="color: rgb(0, 0, 0); letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-stroke-width: 0px; word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space;" class="">Roman Massey</div></div></div>
</div>
<br class=""><div><blockquote type="cite" class=""><div class="">On Jul 2, 2015, at 7:41 AM, Barton Chittenden <<a href="mailto:barton@bywatersolutions.com" class="">barton@bywatersolutions.com</a>> wrote:</div><br class="Apple-interchange-newline"><div class=""><div dir="ltr" class="">In this case, $client is a reference to a hash. You can't print it directly, but you can print the contents using Data::Dumper.<div class=""><br class=""></div><div class="">I think this should work:</div><div class=""><br class=""></div><div class=""><div class=""><font face="monospace, monospace" class="">use Data::Dumper;</font></div><div class=""><font face="monospace, monospace" class="">my $clientcustomfield = RT::CustomFieldValues->new($RT::SystemUser);</font></div><div class=""><font face="monospace, monospace" class="">$clientcustomfield->LimitToCustomField(45);</font></div><div class=""><font face="monospace, monospace" class=""><br class=""></font></div><div class=""><font face="monospace, monospace" class="">my $clients = $clientcustomfield;</font></div><div class=""><font face="monospace, monospace" class=""><br class=""></font></div><div class=""><font face="monospace, monospace" class="">while (my $client = $clients->Next ) {</font></div><div class=""><font face="monospace, monospace" class="">        print dumper $client;</font></div><div class=""><font face="monospace, monospace" class="">        print "\n";</font></div><div class=""><font face="monospace, monospace" class="">}</font></div></div><div class=""><font face="monospace, monospace" class=""><br class=""></font></div><div class=""><font face="monospace, monospace" class=""><br class=""></font></div></div><div class="gmail_extra"><br class=""><div class="gmail_quote">On Wed, Jul 1, 2015 at 10:23 PM, Roman Massey <span dir="ltr" class=""><<a href="mailto:romanmassey@gmail.com" target="_blank" class="">romanmassey@gmail.com</a>></span> wrote:<br class=""><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div style="word-wrap:break-word" class=""><span class="">Hi Guys, Looking for some advice on a script to fetch list of a custom field’s values. At the moment it’s printing "RT::CustomFieldValue=HASH(0x91f22b0)”. I’m obviously missing something silly and would really appreciate a guru’s touch!<br class=""></span><span class=""><br class=""><font face="Courier" class="">my $clientcustomfield = RT::CustomFieldValues->new($RT::SystemUser);<br class="">$clientcustomfield->LimitToCustomField(45);<br class=""><br class="">my $clients = $clientcustomfield;<br class=""><br class="">while (my $client = $clients->Next ) {<br class="">        print $client;<br class="">        print "\n";<br class="">}</font><br class=""></span><span class=""><br class=""></span><span class=""><br class=""></span><div class="">
<div style="letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; word-wrap: break-word;" class=""><div style="letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; word-wrap: break-word;" class=""><div style="letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; word-wrap: break-word;" class="">—</div><span class="HOEnZb"><font color="#888888" class=""><div style="letter-spacing: normal; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; word-spacing: 0px; word-wrap: break-word;" class="">Roman Massey</div></font></span></div></div>
</div>
<br class=""></div></blockquote></div><br class=""></div>
</div></blockquote></div><br class=""></div></body></html>