Look at perl and DBI. Perl has a simple DBI interface
and all the picks have the simple ability to execute local os
programs. You are not going to find any product that does
all the mapping work for you, but perl can quickly do this for
001 SUBROUTINE WHIRLER.DO.SQL(OPT,CMND,RESULT)
002 ** THIS ROUTINE WILL GENERATE A PERL SCRIPT ON THE FLY
004 OPEN 'unix:/tmp/scripts/' TO SCRIPT.FILE ELSE RETURN
005 CODE='use Pg;'; * replace this with specific database driver
007 CODE<-1>="$conn = Pg::connectdb('dbname=":DATABASE:"');"
009 CODE<-1>='$result = $conn->exec("':CMND:'");'
010 IF INDEX(CMND,'SELECT',1) THEN
011 * DOING A SELECT STATEMNET
013 CODE<-1>='while (@d = $result->fetchrow)
014 CODE<-1>=" print
015 CODE<-1>=' print
018 END ELSE
019 CODE<-1>='$r = $result->resultStatus;'
020 CODE<-1>='print $r;'
021 CODE<-1>='print "\n";'
025 WRITE CODE ON SCRIPT.FILE, ID
026 EXECUTE '!perl /tmp/scripts/':ID CAPTURING RESULT
027 DELETE SCRIPT.FILE, ID
028 CONVERT '|' TO CHAR(253) IN RESULT
Now this script connects to Postgres sql database.
It outputs all SQL Select statements as | delimited files.
Now I have used this in pick in the manner you have asked
Use your existing social media logins to access your Membership/Subscription information.
If you are an existing International Spectrum
subscriber, but have not registered with the website, please enter the Reference
Code found on the magazine or in the e-mails you receive from us.
If you currently do not receive the Magazine or other emails from
International Spectrum, select the "Subscribe" button below to create an new membership account.
Find out more about the different between the FREE and a Professional Membership at:
Compare Account Options