Commit Graph

144 Commits

Author SHA1 Message Date
Wez Furlong
fb7d5bd780 The fix for #35332 caused #35671 (and thus PECL #6504).
Partially back out that fix and introduce an extra optional step for drivers to
canonicalize the "name" that is used for registering parameters.
2006-03-27 20:51:01 +00:00
Antony Dovgal
7731dc9421 fix #36727 (segfault in pdo_pgsql bindValue() when no parameters are defined) 2006-03-17 22:15:57 +00:00
Edin Kadribasic
a8dbb0ded6 Be more verbose in phpinfo() output 2006-03-14 10:49:18 +00:00
Edin Kadribasic
c69f100d0e Fixed build 2006-03-13 11:37:51 +00:00
Derick Rethans
1a170a3de2 - Fixed bug #36382 (PDO/PgSQL's getColumnMeta() crashes). 2006-02-13 15:53:36 +00:00
Ilia Alshanetsky
9b0f4a6234 Fixed bug #36176 (PDO_PGSQL - PDO::exec() does not return number of rows
affected by the operation).
2006-01-29 17:35:54 +00:00
foobar
5bd93221a8 bump year and license version 2006-01-01 12:51:34 +00:00
Marcus Boerger
8479546920 - MFH Fix tests 2005-12-31 17:42:39 +00:00
Marcus Boerger
81c25d8700 - Get rid of compiler warnings (both postgres an dphp use these defines) 2005-12-20 21:10:43 +00:00
Ilia Alshanetsky
f7276af1c6 Fixed compiler warning 2005-12-17 18:26:15 +00:00
Ilia Alshanetsky
c2ed71a879 Retry on failed prepare resulting from duplicate statement name. 2005-12-17 17:59:05 +00:00
Marcus Boerger
5e223ad13b - Fix TSRM 2005-12-06 21:44:15 +00:00
foobar
3e669bc950 MFH: nuke php3 legacy 2005-12-06 02:28:41 +00:00
Wez Furlong
17683295e4 switch to package2.xml 2005-12-04 22:34:26 +00:00
Ilia Alshanetsky
4e03ce9fc5 Fixed memory leaks 2005-12-01 16:33:01 +00:00
Ilia Alshanetsky
911355bee8 Fixed memory leak 2005-11-30 23:27:15 +00:00
Ilia Alshanetsky
d79e01e211 Fixed compiler warnings 2005-11-29 18:17:46 +00:00
Wez Furlong
40666b6708 proto fixups 2005-11-29 04:06:03 +00:00
Wez Furlong
131033352d Added PDO::pgsqlLOBCreate(), PDO::pgsqlLOBOpen() and PDO::pgsqlLOBUnlink(). 2005-11-29 02:11:39 +00:00
Wez Furlong
85ad81736c set to 1.0 stable. 2005-11-26 20:50:08 +00:00
foobar
366832fbd2 MFH: Fixed wrong usage of ZEND_EXTENSION_API_NO (these are not Zend exts :) 2005-11-25 16:01:41 +00:00
Wez Furlong
70331c361e Addresses #35338.
Postgres client API is pretty poor, so we have zero idea about the actual
parameter types in a statement.

We now defer the preparation of a statement until the first call to execute is
made.  At that point, we have the parameters defined by the calling script, so
we can use the typing specified there when we perform the prepare.

For PDO_PARAM_LOB parameters, we set the binary formatting flag.

We can't just set this flag for all parameters, because its meaning is not
"string data, counted length" but "data is in native format".  If this flag is
set for a numeric column and we send the number 1 formatted as a string, then
we will get an "insufficient data left in message" error message, because the
library was expecting sizeof(int4) bytes but only saw 1 byte for "1".

This is infuriating because we have no way to determine the datatypes for
parameters, and the type we explicitly set has to match the type in the
database.  The only choice we're left with is telling postgres to deduce the
type; we still have no idea what type was deduced.
2005-11-25 03:35:04 +00:00
Wez Furlong
b6fe60ab52 prep for PECL release 2005-11-01 03:10:09 +00:00
Ilia Alshanetsky
03418c1d36 Fixed test for ZTS builds 2005-10-18 00:15:02 +00:00
Wez Furlong
c19322869b use the right macro for these 2005-10-01 19:19:36 +00:00
Wez Furlong
6cc5e191d0 Refs #34630 2005-09-24 18:47:50 +00:00
Ilia Alshanetsky
0823526afe Fixed test 2005-09-22 16:24:51 +00:00
Ilia Alshanetsky
fe9db9ab0a Remove pointless PDO_ prefix 2005-09-20 00:44:51 +00:00
Ilia Alshanetsky
bfe844e41e MFH: Make PDO use class constants 2005-09-20 00:35:21 +00:00
Wez Furlong
77d3a41f8a update package.xml files and version numbers, in anticipation of a big bunch of releases. 2005-09-11 05:27:30 +00:00
Wez Furlong
edc39221c0 if a php bolean makes it as far as the parameter callback, it must really need
to be boolean; express is as native pgsql 't' or 'f'.

Add a test case for Bug #33876, which is a partially bogus bug.
2005-09-10 21:00:52 +00:00
Edin Kadribasic
38317bb3bd Don't crash on invalid parameter #34203 (Wez) 2005-09-03 23:50:25 +00:00
foobar
23e671a51e - Bumber up year 2005-08-03 14:08:58 +00:00
Wez Furlong
32cf3cc19f Yes, I can't count the months, and no, I'm not related to Ilia. 2005-07-27 04:07:44 +00:00
Wez Furlong
ba77f8515b prep for PECL release 2005-07-27 02:51:01 +00:00
Wez Furlong
79f3cb9856 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.
2005-07-20 02:37:57 +00:00
Ilia Alshanetsky
858d827790 Added cursor closer handler.
Fixed memory leak.
2005-07-09 04:54:04 +00:00
Wez Furlong
6ee00c8199 fix leak 2005-07-08 20:45:19 +00:00
Wez Furlong
6377c0ccca Fix PECL #4753 2005-07-08 19:05:57 +00:00
Wez Furlong
512af63a63 rewrite original names to our preferred format 2005-07-08 17:01:20 +00:00
Ilia Alshanetsky
2301d93156 Some of us don't have PostgreSQL 8.0 :) 2005-07-08 16:20:13 +00:00
Wez Furlong
529d8177fe Add early support for native prepared statements in pgsql.
Note that some tests now fail; if we can't resolve this in time for the beta,
the prepare code should be disabled (I'll add a flag for this later today).
2005-07-08 15:27:34 +00:00
Wez Furlong
4580a7fd8e using new tests 2005-07-07 15:34:46 +00:00
Wez Furlong
b7459aaf7d adopt new tests 2005-07-07 15:20:06 +00:00
Ilia Alshanetsky
6c332449f9 Use PQexecParams() when available, use original case in all other instances. 2005-07-07 13:35:39 +00:00
Ilia Alshanetsky
10e1eecf3f Leave it up to the user to decide if to escape the sequence name or not. 2005-07-07 02:17:20 +00:00
Ilia Alshanetsky
bcb447f6b8 Faster sequence id retrieval. 2005-07-07 00:52:19 +00:00
Wez Furlong
75cfa5c2e0 probable fix for PECL bug #4546 2005-07-03 03:04:13 +00:00
Edin Kadribasic
f05de12fcf Only check for InvalidOid when not looking up a sequence 2005-07-01 22:43:16 +00:00
Edin Kadribasic
7ef1a91508 Fold PQresultErrorField() into a macro 2005-07-01 22:30:55 +00:00