RE: [PHP-DB] Re: PHP and table/view names with '$'
| From: | N dot A dot Morgan at bton dot ac dot uk | Date: | Thu, 23 Apr 2009 11:13:09 +0000 |
| Subject: | RE: [PHP-DB] Re: PHP and table/view names with '$' | ||
| References: | 1 2 | Groups: | php.db |
| Request: | Send a blank email to php-db+get-46139@lists.php.net to get a copy of this message | ||
Escape the embedded single quotes i.e.
$stmt = OCIParse($conn, 'SELECT * FROM v$sql WHERE
INSTR(SQL_TEXT,\'something\')>0');
Neil
-----Original Message-----
From: Mark Casson [mailto:confused@icube.co.uk]
Sent: 23 April 2009 12:10
To: php-db@lists.php.net
Subject: [PHP-DB] Re: PHP and table/view names with '$'
Hi,
Of course, the next problem is that i want to specify a line to find:
$stmt = OCIParse($conn, 'SELECT * FROM v$sql WHERE
INSTR(SQL_TEXT,'something')>0');
and i seem to have to use single quotes in the INSTR function.
Is there an alternative way to deal with that?
Thanks again
Mark
""Mark Casson"" <confused@icube.co.uk> wrote in message
news:89.4E.33545.C2D30F94@pb1.pair.com...
> Hi,
>
> I am trying to access some of the v$ views using php on iis, with
admin
> privileges.
>
> However, using:
>
> $stmt = OCIParse($conn, "SELECT * FROM v$sql");
>
> gives me this error:
>
> PHP Notice: undefined variable: sql . . .
>
> Is there a way around this?
>
> Thanks
>
> Mark
>
--
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php