# Announce: PDO beta releases

- Thread: https://externals.io/message/14736
- Original archive: https://news-web.php.net/php.internals/14736
- Started by Wez Furlong on 2005-02-09T05:55:46+00:00
- Messages: 23
- Reply by email to internals@lists.php.net
- More for agents: search with https://externals.io/search.md?q={query} · JSON API at https://externals.io/api · documentation at https://externals.io/llms.txt

---

## #14736 — Wez Furlong — 2005-02-09T05:55:46+00:00

URL: https://externals.io/message/14736#14736

You may have noticed my "drive-by release" of various different PDO
packages tonight/this morning.

This is stage one of the "PDO push".

I'd like to encourage you all to try it out; as you should know, we're
going to be releasing PDO as part of PHP 5.1, so we need as many
people as possible to play around with it to discover any remaining
issues.

Some drivers have had more testing and support than others, simply
because they are easier or more convenient to develop and test
against.

If you find any missing features, inconsistencies between drivers,
bugs or crashes, please report them using the PECL bug tracking
system.  Please categorize bugs correctly, and, if possible, try out
more than one driver.  If you have the same problem for more than one
driver, report the bug using the PDO bug reporting page, otherwise use
the bug reporting page for your driver.  The bug reporting pages can
be found by visiting http://pecl.php.net/<extensionname> and clicking
on the "Package Bugs" link.  Please don't submit the same problem more
than once; add your feedback to existing bugs if it is appropriate.

During the PDO push, I want to release updated PDO packages at the end
of each day in which a bug is found and fixed.  Please help me with
this task by reporting any issues as clearly and completely as
possible.  Now is the time to test and evaluate PDO; if we don't get
enough feedback over the next couple of weeks, it won't make it into
PHP 5.1 and you'll have to wait until the next major PHP release.

You'll no doubt be wondering how to use PDO, so here are some useful resources:

The PHP manual:
http://www.php.net/manual/en/ref.pdo.php

Various posts from my blog; some information is slightly outdated, one
of the links includes slides from one of my talks on PDO at the
php|works conference last year:

http://netevil.org/node.php?uuid=41572e4a-0757-8311-6093-1572e4a93e1b
http://netevil.org/node.php?uuid=415464e0-6270-1081-4799-15464e02aa74
http://netevil.org/node.php?uuid=a1907cf3-1afc-4ffe-b36b-a17b405fbeb5
http://netevil.org/node.php?uuid=bf0a58d7-68ab-49d0-9a29-f5ec97c5dfde

My article on the Oracle Technology Network giving an overview of PDO.
Again, some information my be slightly outdated.
http://www.oracle.com/technology/pub/articles/php_experts/otn_pdo_oracle5.html

Also during the PDO push, I'll be working with Dan to help flesh out
the official PHP documentation for PDO, and quite probably blogging
little handy snippets for some of the newer/more advanced features.

Thanks for your attention, and looking forward to your feedback.

--Wez.

---

## #14738 — Daniel Convissor — 2005-02-09T06:32:08+00:00

URL: https://externals.io/message/14736#14738 · In reply to: #14736

Hi Wez:


> 
> I'd like to encourage you all to try it out; as you should know, we're
> going to be releasing PDO as part of PHP 5.1, so we need as many
> people as possible to play around with it to discover any remaining
> issues.
...
> If you find any missing features, inconsistencies between drivers,
> bugs or crashes, please report them using the PECL bug tracking

Do you have a set of test scripts somewhere that should produce the 
same results regardless of which driver is being used?  Kind of like the 
PEAR DB test suite.  Or is each individual person going to have to make up 
their own tests?

Thanks,

--Dan

-- 
 T H E   A N A L Y S I S   A N D   S O L U T I O N S   C O M P A N Y
            data intensive web and database programming
                http://www.AnalysisAndSolutions.com/
 4015 7th Ave #4, Brooklyn NY 11232  v: 718-854-0335 f: 718-854-0409

---

## #14739 — Wez Furlong — 2005-02-09T07:04:22+00:00

URL: https://externals.io/message/14736#14739 · In reply to: #14738

Dan Scott mentioned to me that he has someone that is (or soon will
be) working on a test suite.

While a test-suite is good, it's also good for people to actually sit
down and try to use it in their own way.

--Wez.

On Wed, 9 Feb 2005 01:32:08 -0500, Daniel Convissor
<danielc@analysisandsolutions.com> wrote:
> Hi Wez:
> 
> 
> > […]
> ...
> > […]
> 
> Do you have a set of test scripts somewhere that should produce the
> same results regardless of which driver is being used?  Kind of like the
> PEAR DB test suite.  Or is each individual person going to have to make up
> their own tests?

---

## #14740 — D.Walsh — 2005-02-09T08:06:55+00:00

URL: https://externals.io/message/14736#14740 · In reply to: #14739

Is there a mysterious trick to use it on Mac OSX 10.3.x??

-- Dale



> Dan Scott mentioned to me that he has someone that is (or soon will
> be) working on a test suite.
>
> While a test-suite is good, it's also good for people to actually sit
> down and try to use it in their own way.
>
> --Wez.
>
> On Wed, 9 Feb 2005 01:32:08 -0500, Daniel Convissor
> <danielc@analysisandsolutions.com> wrote:
> > […]

---

## #14742 — Lester Caine — 2005-02-09T08:41:50+00:00

URL: https://externals.io/message/14736#14742 · In reply to: #14736

Wez Furlong wrote:

> I'd like to encourage you all to try it out; as you should know, we're
> going to be releasing PDO as part of PHP 5.1, so we need as many
> people as possible to play around with it to discover any remaining
> issues.

As a longtime user of ADOdb, converting to something new may not be 
practical, but at least Firebird is on the list which makes a nice change.

I'm not seeing an easy route to getting hold of a copy to play with 
(windows :( ) and I'm not seeing much in the function list yet. Can 
anybody give any feedback on what is missing at the moment mapped 
against ADOdb functionality?

Is it worth me spending time digging into this just yet, or should I 
wait for some of missing functionality to be addressed ;)

-- 
Lester Caine
-----------------------------
L.S.Caine Electronic Services

---

## #14747 — Wez Furlong — 2005-02-09T15:04:11+00:00

URL: https://externals.io/message/14736#14747 · In reply to: #14742

> I'm not seeing an easy route to getting hold of a copy to play with
> (windows :( ) and I'm not seeing much in the function list yet.

http://snaps.php.net/win32/PECL_5_0/ has binaries for all PDO packages
(including MS-SQL, which doesn't show up in the PECL package list
yet).
 
> Is it worth me spending time digging into this just yet, or should I
> wait for some of missing functionality to be addressed ;)

The API is feature complete (although some drivers don't implement as
many features as they could yet).

NOW is the time to investigate it for yourself; it will be too late otherwise.

--Wez.

---

## #14748 — Dan Scott — 2005-02-09T15:18:59+00:00

URL: https://externals.io/message/14736#14748 · In reply to: #14736

> You may have noticed my "drive-by release" of various different PDO
> packages tonight/this morning.
> 
> This is stage one of the "PDO push".

Woo-hoo! The world rejoices (well, at least this small part of the world).

<snip />
 
> The PHP manual:
> http://www.php.net/manual/en/ref.pdo.php

I've committed a number of changes since the manual was last built; is
there a manual refresh in the works, or would Livedocs be able to
handle the testers' load if we linked to that?

To stay in sync with Wez, I would like to be able to ensure that
testers / early adopters are using the latest docs (particularly if
the API needs to change), thus avoiding the filing of bogus bugs as
much as possible...

Dan

---

## #14749 — Sean Coates — 2005-02-09T15:30:53+00:00

URL: https://externals.io/message/14736#14749 · In reply to: #14748

Dan Scott wrote:
> > […]
> 
> I've committed a number of changes since the manual was last built; is
> there a manual refresh in the works, or would Livedocs be able to
> handle the testers' load if we linked to that?

http://livedocs.phpdoc.info/pdo

Please play nicely with my bandwidth.

S

---

## #14754 — Jacques Marneweck — 2005-02-09T16:18:43+00:00

URL: https://externals.io/message/14736#14754 · In reply to: #14748

Dan Scott wrote:

>
>  
>
>I've committed a number of changes since the manual was last built; is
>there a manual refresh in the works, or would Livedocs be able to
>handle the testers' load if we linked to that?
>
>To stay in sync with Wez, I would like to be able to ensure that
>testers / early adopters are using the latest docs (particularly if
>the API needs to change), thus avoiding the filing of bogus bugs as
>much as possible...
>
>Dan
>  
>
Hi Dan,

The livedocs over on http://livedocs.php.mirrors.powertrip.co.za/ 
updates every two hours via a cron job.  If need be I can hook up 
another box to serve the livedocs site as well depending on the load on 
that box which currently serves the livedocs and setup DNS round robin.

The box uses the turck mmcache to boost PHP performance, so I'd love to 
actually throw some load against livedocs to test it.

Regards
--jm

---

## #14759 — Wez Furlong — 2005-02-09T16:25:08+00:00

URL: https://externals.io/message/14736#14759 · In reply to: #14754

We've kicked off a doc build for php.net; it should update "soon" and
percolate down to the mirrors.

--Wez.



> Dan Scott wrote:
> 
> > […]
> Hi Dan,
> 
> The livedocs over on http://livedocs.php.mirrors.powertrip.co.za/
> updates every two hours via a cron job.  If need be I can hook up
> another box to serve the livedocs site as well depending on the load on
> that box which currently serves the livedocs and setup DNS round robin.
> 
> The box uses the turck mmcache to boost PHP performance, so I'd love to
> actually throw some load against livedocs to test it.
> 
> Regards
> --jm
> 
> --
> PECL development discussion Mailing List (http://pecl.php.net/)

---

## #14755 — Lester Caine — 2005-02-09T16:28:38+00:00

URL: https://externals.io/message/14736#14755 · In reply to: #14747

Wez Furlong wrote:

> > […]
> 
> http://snaps.php.net/win32/PECL_5_0/ has binaries for all PDO packages
> (including MS-SQL, which doesn't show up in the PECL package list
> yet).

Somewhere I've not been before ;)

> > […]
> 
> The API is feature complete (although some drivers don't implement as
> many features as they could yet).

How are Blob references handled?
Sequence management?
No Caching?
How do we access metadata?
LIMIT/FIRST management in SQL?

> NOW is the time to investigate it for yourself; it will be too late otherwise.

I start with a check that the tables I need exist, independent of the 
different SQL requirements of the different engines. On a quick 
overview, there is nothing to replace MetaTables() ?
ADOdb makes differences in SQL formats between databases transparent, is 
that something that PDO will address?
The other area is transparent creation of databases independent of engine.
What I am seeing at the moment is only a subset of the problem addressed.

-- 
Lester Caine
-----------------------------
L.S.Caine Electronic Services

---

## #14757 — Wez Furlong — 2005-02-09T16:41:26+00:00

URL: https://externals.io/message/14736#14757 · In reply to: #14755

Please read the various links that I posted in the announcement; they
explain a number of design goals about PDO (particularly the OTN
article) that will answer your questions in more detail.

Here are some quick answers:


> How are Blob references handled?

As streams.  This is still not fully supported in all places yet; it
should have better support and docs over this next week.

> Sequence management?

None.

> No Caching?

None.

> How do we access metadata?

There are methods.

> LIMIT/FIRST management in SQL?

None.  Consider scrollable cursors as an alternative for databases
that don't have LIMIT/FIRST.

> I start with a check that the tables I need exist, independent of the
> different SQL requirements of the different engines. On a quick
> overview, there is nothing to replace MetaTables() ?
> ADOdb makes differences in SQL formats between databases transparent, is
> that something that PDO will address?

No.  That is something for another layer.  PDO is intended to be a
very light layer with minimal interference.

> The other area is transparent creation of databases independent of engine.
> What I am seeing at the moment is only a subset of the problem addressed.

Not in this release of PDO.
 
--Wez.

---

## #14761 — Lester Caine — 2005-02-09T17:16:07+00:00

URL: https://externals.io/message/14736#14761 · In reply to: #14757

Wez Furlong wrote:

> Please read the various links that I posted in the announcement; they
> explain a number of design goals about PDO (particularly the OTN
> article) that will answer your questions in more detail.

Not into Oracle ;) , but it answers the main questions. PDO is not 
planned to be a replacement for ADOdb.

> No.  That is something for another layer.  PDO is intended to be a
> very light layer with minimal interference.

Until all engines can use the same SQL there is little point in a 
generic layer that means you have to re-engineer the queries when ever 
you switch engines ? Unless it is very much faster than the existing 
drivers, in which case I'd switch the Firebird ADOdb driver to use it :)
So I'm looking at a different level of the Abstraction Model.

It's bad enough catering for the differences AFTER ADOdb has taken off 
the rough spots ;)

-- 
Lester Caine
-----------------------------
L.S.Caine Electronic Services

---

## #14762 — Wez Furlong — 2005-02-09T17:25:32+00:00

URL: https://externals.io/message/14736#14762 · In reply to: #14761

> Not into Oracle ;) , but it answers the main questions. PDO is not
> planned to be a replacement for ADOdb.

Correct.
 
> > […]
> 
> Until all engines can use the same SQL there is little point in a
> generic layer that means you have to re-engineer the queries when ever
> you switch engines ? Unless it is very much faster than the existing
> drivers, in which case I'd switch the Firebird ADOdb driver to use it :)
> So I'm looking at a different level of the Abstraction Model.

One of the major aims of PDO is to eventually replace the existing
database extensions in PHP, not to provide total abstraction (which is
a impossible goal in the opinions of many seasoned developers).
 
--Wez.

---

## #14763 — Lukas Smith — 2005-02-09T17:43:52+00:00

URL: https://externals.io/message/14736#14763 · In reply to: #14761

Lester Caine wrote:

> Not into Oracle ;) , but it answers the main questions. PDO is not 
> planned to be a replacement for ADOdb.
> 
> > […]
> 
> 
> Until all engines can use the same SQL there is little point in a 
> generic layer that means you have to re-engineer the queries when ever 
> you switch engines ? Unless it is very much faster than the existing 
> drivers, in which case I'd switch the Firebird ADOdb driver to use it :)
> So I'm looking at a different level of the Abstraction Model.
> 
> It's bad enough catering for the differences AFTER ADOdb has taken off 
> the rough spots ;)

There are two parts to database abstraction.

1) client API
2) SQL

PDO addresses 1) quite nicely and takes very specific stabs at 2) .. 
mainly prepare/execute, error codes, LOB

Anything beyond that gets to ugly that its probably more feasible to do 
in PHP userland anyways. This was the original intention of the 
extension and it has remained unchanged todate.

We are lobbying Oracle to add limit support, but thats another topic.

BTW: I am working on PEAR::MDB2 to become as API compatible as possible 
with PDO. This has the benefit of giving a PHP4 package that people can 
use today with the PDO API so that they can move to PDO easily once they 
are ready to make the jump to PHP5. Also this will enable people to 
easily move to MDB2 from PDO if they need the additional abstraction. At 
the same time I will eventually also provide PDO based drivers which 
should be much improved in speed (and maintainability) compared to the 
old drivers. Contributions are welcome :-)

regards,
Lukas

---

## #14768 — Rasmus Lerdorf — 2005-02-09T18:52:22+00:00

URL: https://externals.io/message/14736#14768 · In reply to: #14763

Lukas Smith wrote:
> We are lobbying Oracle to add limit support, but thats another topic.

If that happens I want royalties!

-Rasmus

---

## #14769 — Lester Caine — 2005-02-09T19:02:31+00:00

URL: https://externals.io/message/14736#14769 · In reply to: #14762

Wez Furlong wrote:

> One of the major aims of PDO is to eventually replace the existing
> database extensions in PHP, not to provide total abstraction (which is
> a impossible goal in the opinions of many seasoned developers).

Have not found a problem building cross database packages. As long as 
you avoid STARTING from MySQL, then most things can be transparent. It 
would be nice to link in 'Triggers' but until the other engines support 
them properly ...
Total abstraction does require removing some of the inconsistencies in 
SQL, but it is certainly not impossible. It MAY be 'expensive' in terms 
of processing time, but that is the trade off between single engine code 
and generic anyway.

Lukas - I see little point in trying to get LIMIT into Oracle until the 
preferred method of working is included in SQL2003. MSSQL would need 
convincing to change it as well, but I prefer the more natural SELECT 
FIRST n SKIP x. So LIMIT n OFFSET x is not a 'done deal' ;)
There are a lot more subtle variations which cause a lot more problems 
than that anyway :)

-- 
Lester Caine
-----------------------------
L.S.Caine Electronic Services

---

## #14776 — Jacques Marneweck — 2005-02-09T22:04:09+00:00

URL: https://externals.io/message/14736#14776 · In reply to: #14759

Wez Furlong wrote:

>We've kicked off a doc build for php.net; it should update "soon" and
>percolate down to the mirrors.
>
>--Wez.
>  
>
Hi Wez,

In the interim I've fixed the issue with http://livedocs.php.mirrors.powertrip.co.za/ and it includes the pdo docs. :)

Regards
--jm

---

## #14777 — Marc Richards — 2005-02-10T00:45:34+00:00

URL: https://externals.io/message/14736#14777 · In reply to: #14736

Wez Furlong wrote:
> You may have noticed my "drive-by release" of various different PDO
> packages tonight/this morning.
> 
> This is stage one of the "PDO push".

Are there plans for a mysqli driver for PDO? I searched around but I 
couldn't seem to find an answer.

Is it a technical limitation or simply a lack of resources? Not trying 
to be pushy, I am just curious.


Marc

---

## #14778 — George Schlossnagle — 2005-02-10T01:07:48+00:00

URL: https://externals.io/message/14736#14778 · In reply to: #14777

> Wez Furlong wrote:
> > […]
>
> Are there plans for a mysqli driver for PDO? I searched around but I 
> couldn't seem to find an answer.
>
> Is it a technical limitation or simply a lack of resources? Not trying 
> to be pushy, I am just curious.

I volunteered to do it if no one else did, but I keep failing to find 
hours 30 and 31 in my day.

George

---

## #14779 — Marc Richards — 2005-02-10T02:14:41+00:00

URL: https://externals.io/message/14736#14779 · In reply to: #14778

George Schlossnagle wrote:
> 
> 
> 
> > […]
> 
> 
> I volunteered to do it if no one else did, but I keep failing to find 
> hours 30 and 31 in my day.
> 
> George

I know how you feel.  Thanks for responding.


Marc

---

## #14783 — John Coggeshall — 2005-02-10T08:05:07+00:00

URL: https://externals.io/message/14736#14783 · In reply to: #14779

I've been itching to code, and I actually wrote this once upon a time
and lost it when my laptop harddrive bombed. 

I'll take this up and try to get it out by Monday -- I don't have much
planned for the weekend.

Cheers,

John


> George Schlossnagle wrote:
> > […]
> 
> I know how you feel.  Thanks for responding.
> 
> 
> Marc

---

## #14808 — Marc Richards — 2005-02-10T22:37:42+00:00

URL: https://externals.io/message/14736#14808 · In reply to: #14783

awesome.  good luck.


Marc

John Coggeshall wrote:
> I've been itching to code, and I actually wrote this once upon a time
> and lost it when my laptop harddrive bombed. 
> 
> I'll take this up and try to get it out by Monday -- I don't have much
> planned for the weekend.
> 
> Cheers,
> 
> John
> 
> 
> 
> > […]
