Re: [PDO] Asynchronous requests
[email protected] (Lester Caine) Tue, 03 Nov 2009 14:06:41 +0000
| Newsgroups | php.pdo |
|---|---|
| Message-ID | <[email protected]> |
Lukas Kahwe Smith wrote: > To me the question is just when a feature is ready to become part of the > unified layer and how to deal with features we are not yet sure about. > > like with async .. lets say for now we are not yet sure enough about a > unified API so we prefix: > PDO_MySQL::mysqlAsyncQuery() > PDO:PgSQL::pgsqlAsyncQuery() > > one day we become more comfortable and add it to PDO core throwing an > error/exception if the feature is not available: > PDO::asyncQuery() I think this highlights the different views and may explain why we have a problem at present. In the past I've been told - add the Firebird specific services interface to pdo_firebird and then you can drop the php_interbase. That seems totally the wrong way of doing things if the intention is that PDO is providing a level playing field as an API for data. Merging all of the services function in php_interbase would take some time, but could be done. However the intention is to eventually remove the need to use this interface and just use SQL queries to handle the same thing. So there is little point spending a lot of time on something that will eventually be dropped anyway. The firebird developers are working to provide an API that can work with any SQL interface rather than needing special code for these extras. So what is asyncQuery() ... if it's a query in a new transaction space, then it just needs a separate connection to use it. If it's simply processing the data records as they arrive rather than waiting for the complete result set, then that is how *I* normally work anyway. I do think that we are probably still working to different ends? While PDO has no interest in the content of the SQL, any reason to change from generic drivers should have cross database working at least anticipated. Just designing a rather clunky one size fits all driver that then needs another layer to make it switch between engines is just pointless? -- Lester Caine - G8HFL ----------------------------- Contact - http://lsces.co.uk/wiki/?page=contact L.S.Caine Electronic Services - http://lsces.co.uk EnquirySolve - http://enquirysolve.com/ Model Engineers Digital Workshop - http://medw.co.uk// Firebird - http://www.firebirdsql.org/index.php