in reply to Re^4: CGI-SQL Query Issue
in thread CGI-SQL Query Issue

Does it work if you put the dates in the SQL ?

between to_date('20160303','YYYYMMDD') and to_date('20160320','YYYYMMDD')
poj

Replies are listed 'Best First'.
Re^6: CGI-SQL Query Issue
by Anonymous Monk on Mar 18, 2016 at 12:15 UTC
    NO, same result as before. That's the whole problem, SQL query is not working.

      Create a file called dual.sql in cgi-bin with these 2 lines

      select SYSDATE from dual; exit;

      Create and access this cgi program

      #!/usr/bin/perl use strict; use warnings; use CGI; use CGI::Carp 'fatalsToBrowser'; my $sqlfile = '/var/www/cgi-bin/dual.sql'; my $q = new CGI; my $connstr = 'USER/PASSWORD@DB'; my $msg = qx"sqlplus -s $connstr \@$sqlfile"; print $q->header,$q->start_html, $q->pre($msg),$q->end_html;
      poj
        Hi, When I run this script, with this sql configured, I don't get any result on the web page. SQL does not seem to work. Regards