just because you CAN use delimited identifiers doesn’t mean

you SHOULD use them.  In general, they end up causing way more problems than they solve.

Portability is broken by using the following characters inside delimited identifiers:

  • backtick (<kbd>`</kbd>) -- due to MySQL
  • double quote (<kbd>”</kbd>) -- due to Oracle
  • brackets (<kbd>[</kbd> or <kbd>]</kbd>) -- due to Access

Delimited identifiers are known to generally work correctly under the following drivers:

  • mssql
  • mysql
  • mysqli
  • oci8
  • odbc(access)
  • odbc(db2)
  • pgsql
  • sqlite
  • sybase (must execute <kbd>set quoted_identifier on</kbd> sometime prior to use)

InterBase doesn’t seem to be able to use delimited identifiers via PHP 4.  They work fine under PHP 5.

@param string $str the identifier name to be quoted

@return string the quoted identifier

@since Method available since Release 1.6.0