function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
cpinacpina 

Salesforce Perl module

Hello,

I'm trying to use SalesForce Perl module (documentation is available in . I get from one example:
Code:
#!/usr/bin/perl

use Salesforce;

my $service = new Salesforce::SforceService;
my $port = $service->get_port_binding('Soap');
my $result = $port->login('username' => $user, 'password' => $pass);

$result = $port->search('searchString' => 'find {1234} in phone fields returning contact(id, phone, firstname, lastname), lead(id, phone, firstname, lastname), account(id, phone, name)');

But how I can get the result? Using query and select I can get the results executing:

Code:
foreach my $elem ($result->valueof('//searchStringResponse/result/records')) {
    printf "%s, %s\n", $elem->{Id},$elem->{Name};
}

And is working fine. But, using fine, how I can retrieve the results?

Thank you very much,

Carles