[lug] php/oracle question (somewhat OT)

Chip Atkinson chip at rmpg.org
Mon Jun 17 13:44:56 MDT 2002


Same error, quoting or not.  I am starting to wonder if php was built
improperly somehow or that there are config issues.

Chip
On Mon, 17 Jun 2002, D. Stimits wrote:

> Chip Atkinson wrote:
> >
> > Posting the code is a good idea, I'll do that below.  I've used php/mysql
> > before and really liked it, probably due to the ease of use. :-)
> > The php code below using oracle have been giving me fits though.
> >
> > TIA,
> >
> > Chip
> >
> > $conn = ora_logon("user", "password"); // Not the real values here of course
> >
> > $query = "SELECT
> >             acct acct, name, docdt, docnm, ROWID
> >           FROM
> >             onlstm_cont c
> >           WHERE
> >             acct=1111 and cu='abcd'
> >           ORDER BY
> >             name, acct,ssn, docdt, docnm";
> >
> > /* This one seems to work if there is only one row.
> >  * If more than one row, we get an oracle error, 1422,
> >  * exact fetch returns more than requested number of rows.
> >  */
> > $query2 = "declare tmp char(40);
> >            begin
> >              select ufsnm into :tmp from onlstm_cont
> >              where acct=1111 and cu='abcd';
> >           end;";
> ...
>
> Just a guess since I don't know anything about oracle, but does the
> error change when you also quote the acct value, e.g., account='1111'?
>
> D. Stimits, stimits at idcomm.com
> _______________________________________________
> Web Page:  http://lug.boulder.co.us
> Mailing List: http://lists.lug.boulder.co.us/mailman/listinfo/lug
> Join us on IRC: lug.boulder.co.us port=6667 channel=#colug
>




More information about the LUG mailing list