Here is more of the script in question: . .
} elsif ($Product) { sql(); $port = $Product; $Field = 'Product'; ProcessSQL(); . . . sub sql { $SQLCommand = <<SQL; SELECT Client,Product,Issue,Cause,Date,id,Call FROM support WHERE Client LIKE ? AND Product LIKE ? AND Issue LIKE ? AND Cause LIKE ? AND SupportDetails LIKE ? AND Date LIKE ? SQL } . . . sub ProcessSQL { ExecuteSQL(); print; close_dbi($dbh); } . . . sub ExecuteSQL { $dbh = open_dbi(); print "<body bgcolor='#FFFFCC'> <TABLE BORDER=0 width=840 cellpadding=2 align=center bordercol +or='#FF9933' bgcolor='#FF9933'> <TR><TH><font face=Arial size=2>Edit</TH><TH><font face=Arial size=2>R +eg. No.</TH><TH><font face=Arial size=2>Product</TH><TH><font face=Ar +ial size=2>Issue</TH><TH><font face=Arial size=2>Cause</TH> <TH><font face=Arial size=2>Date</TH><th><font face=Ar +ial size=2>Case</th></TR> <font face='Courier'> <form name='form1' method='POST' action='ISeeSupportViewDetail +s.pl'> <p>"; my $sth = $dbh->prepare("$SQLCommand") or err_trap("Cannot pre +pare the load_category_names query"); $sth->execute($Client,$Product,$Issue,$Cause,$SupportDetails,$ +Date) or err_trap("Cannot execute the SQL query to SQL COMMAND"); $i=1; while (($Client,$Product,$Issue,$Cause,$Date,$filler,$Call) = +$sth->fetchrow_array) { print "<Tr> <td width='15' height='20' bordercolor='#FFFFCC' bgcol +or='#FFFFCC'>"; print ("<input type='radio' name='radio' value='$i' >" +); print "</td> <td width='60' height='20' align='left' bordercolor='# +FFFFCC' bgcolor='#FFFFCC'><font face= 'Arial' size='1'>&nbsp;$Client</td> <td width='100' height='20' align='left' bordercolor=' +#FFFFCC' bgcolor='#FFFFCC'><font face= 'Arial' size='1'>&nbsp;$Product</td> <td width='220' height='20' align='left' bordercolor=' +#FFFFCC' bgcolor='#FFFFCC'><font face= 'Arial' size='1'>&nbsp;$Issue</td> <td width='220' height='20' align='left' . . .

In reply to Re: Re: Passing data from one perl script to another. by sdyates
in thread Problem constructing an SQL query with LIKE clauses by sdyates

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post, it's "PerlMonks-approved HTML":



  • Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
  • Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
  • Read Where should I post X? if you're not absolutely sure you're posting in the right place.
  • Please read these before you post! —
  • Posts may use any of the Perl Monks Approved HTML tags:
    a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
  • You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
            For:     Use:
    & &amp;
    < &lt;
    > &gt;
    [ &#91;
    ] &#93;
  • Link using PerlMonks shortcuts! What shortcuts can I use for linking?
  • See Writeup Formatting Tips and other pages linked from there for more info.