vBulletin Search Engine Optimization
| |||||||
| Register | FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| ||||
| This seems like a very bad impl - at least for JDBC. Why are the details of this access not hidden in the JDBC driver? The column type is the only thing that a user should be concerned with. Why would someone want to code proprietary Postgres code just to access BLOBs? The JDBC blob API is very good. Using either the BLOB/locator interface or the getInputStream(); Oracle used to do a similar thing, and finally got with the program and uses strict JDBC in their latest driver releases. -- Sent via pgsql-jdbc mailing list (pgsql-jdbc@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-jdbc |
| |||
| robert engels wrote: > This seems like a very bad impl - at least for JDBC. > > Why are the details of this access not hidden in the JDBC driver? The > column type is the only thing that a user should be concerned with. > > Why would someone want to code proprietary Postgres code just to access > BLOBs? > > The JDBC blob API is very good. Using either the BLOB/locator interface > or the getInputStream(); > I think you've misunderstood me. The documentation shows using a proprietary API, but get/setBlob works just fine. I pointed to the documentation because it explains some of the differences between the bytea and large object datatypes. It's really that the documentation needs an additional example for the standard blob usage. Kris Jurka -- Sent via pgsql-jdbc mailing list (pgsql-jdbc@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-jdbc |
| ||||
| That's good to know. The spec allows BLOBs to be read using getBytes() and getBinaryStream () as well. getBinaryStream should allow bytea to be read without allocating an array to hold all of the data. BUT, the low-level db protocol would need to support reading the column in chunks. On May 1, 2008, at 6:44 PM, Kris Jurka wrote: > > > robert engels wrote: >> This seems like a very bad impl - at least for JDBC. >> Why are the details of this access not hidden in the JDBC driver? >> The column type is the only thing that a user should be concerned >> with. >> Why would someone want to code proprietary Postgres code just to >> access BLOBs? >> The JDBC blob API is very good. Using either the BLOB/locator >> interface or the getInputStream(); > > I think you've misunderstood me. The documentation shows using a > proprietary API, but get/setBlob works just fine. I pointed to the > documentation because it explains some of the differences between > the bytea and large object datatypes. It's really that the > documentation needs an additional example for the standard blob usage. > > Kris Jurka > -- Sent via pgsql-jdbc mailing list (pgsql-jdbc@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-jdbc |
| Thread Tools | |
| Display Modes | |
| |