v5:reference:connection:param
Differences
This shows you the differences between two versions of the page.
Next revision | Previous revisionNext revisionBoth sides next revision | ||
reference:param [2015/08/21 20:58] – created mnewnham | v5:reference:connection:param [2020/01/24 23:48] – [Description] document param(false) call to reset counter dregad | ||
---|---|---|---|
Line 2: | Line 2: | ||
~~NOTOC~~ | ~~NOTOC~~ | ||
<WRAP right box> | <WRAP right box> | ||
+ | ==See Also== | ||
+ | [[v5: | ||
== Syntax == | == Syntax == | ||
string param( | string param( | ||
- | | + | |
- | | + | |
) | ) | ||
</ | </ | ||
===== Description ===== | ===== Description ===== | ||
The function param returns a database-specific placeholder for a prepared query statement. | The function param returns a database-specific placeholder for a prepared query statement. | ||
+ | |||
+ | This method is used with [[v5: | ||
+ | |||
+ | On RDBMS with positional (numbered) query parameters such as PostgreSQL, calling '' | ||
+ | |||
+ | ------------------------------ | ||
===== Usage ===== | ===== Usage ===== | ||
<code php> | <code php> | ||
Line 29: | Line 36: | ||
*/ | */ | ||
</ | </ | ||
+ | <code php> | ||
+ | /* | ||
+ | * Connection to Postgres database | ||
+ | */ | ||
+ | print $db-> | ||
+ | /* | ||
+ | * prints $1 | ||
+ | */ | ||
+ | </ | ||
+ | |||
v5/reference/connection/param.txt · Last modified: 2021/02/26 01:35 by dregad