Search Postgresql Archives

Re: problem with serial

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 





2012/4/19 Raymond O'Donnell <rod@xxxxxx>
Or better still - and easier - use parametrised queries.


Right it is easier something like :
$sql = "categories (idx, ctime, mtime, name) VALUES ( :idx, :ctime, :mtime, :name);";
$prep = $db->prepare($sql);
$prep->execute( array(':idx' => $_GET['idx'], ':ctime' => $ctime, ':mtime' => $mtime, ':name' => $name));

no more need to $db->quote()  in that case, as :
$name = $db->quote($name);
???
I mean, even if $name = "L'envers" ? (ie. with a ' in it ?)
--
Yvon



[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]
  Powered by Linux