summaryrefslogtreecommitdiff
path: root/ext/pdo_pgsql/php_pdo_pgsql_int.h
diff options
context:
space:
mode:
authorWez Furlong <wez@php.net>2005-07-20 02:37:57 +0000
committerWez Furlong <wez@php.net>2005-07-20 02:37:57 +0000
commit79f3cb9856abe0537f3fbd6004c7e2ed82aaeb84 (patch)
tree58bbf8973b24d53221ac91780ab884ce8c91eed7 /ext/pdo_pgsql/php_pdo_pgsql_int.h
parent9438584d76a6ac7d3bef3535511d3251c6a0ada6 (diff)
downloadphp-git-79f3cb9856abe0537f3fbd6004c7e2ed82aaeb84.tar.gz
Add PDO_PGSQL_ATTR_DISABLE_NATIVE_PREPARED_STATEMENT attribute, which, when set
to true, forces the driver to use PDO's own emulated prepared statement support. Why would you want that, considering that native prepared statements are supposed to be the best thing ever? "Often postgresql will have to plan the query without knowing the parameters - and it will choose a bad plan. In some cases it will plan based on the first parameters you send. " Ugh. So now we have a way to let you decide that you know better than the pgsql query planner.
Diffstat (limited to 'ext/pdo_pgsql/php_pdo_pgsql_int.h')
-rw-r--r--ext/pdo_pgsql/php_pdo_pgsql_int.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/ext/pdo_pgsql/php_pdo_pgsql_int.h b/ext/pdo_pgsql/php_pdo_pgsql_int.h
index 43633f4f63..855c934488 100644
--- a/ext/pdo_pgsql/php_pdo_pgsql_int.h
+++ b/ext/pdo_pgsql/php_pdo_pgsql_int.h
@@ -84,6 +84,10 @@ extern struct pdo_stmt_methods pgsql_stmt_methods;
#define pdo_pgsql_sqlstate(r) (const char *)NULL
#endif
+enum {
+ PDO_PGSQL_ATTR_DISABLE_NATIVE_PREPARED_STATEMENT = PDO_ATTR_DRIVER_SPECIFIC,
+};
+
#endif /* PHP_PDO_PGSQL_INT_H */
/*