in reply to Perl/DBI/Oracle and strings with spaces
<BR>$sth=$dbh->prepare(q{SELECT this FROM that WHERE <BR>foo=?}); <BR>$sth->execute($findthis); <BR>($returnme) = $sth->fetchrow_array(); but that doesn't handle strings that contain spaces. I've tried a nu +mber of di fferent ways of doing it to handle spaces... and all fail. I tried qq{}, taking it out of q{} like:
I suspect the real reason the above doesn't work (assuming that is exactly the code) is that you have aparent HTML in the SQL. Also, I am curious about the leading <BR>'s in the code snippet.
select x from y where <BR>this=?
is certainly going to cause oracle to complain.
if you can pass the same sql via DBI that you are using in SQL*Plus, you will be successful.
you are close...good luck
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Perl/DBI/Oracle and strings with spaces
by Fastolfe (Vicar) on Dec 10, 2000 at 09:35 UTC |