From: | David Bernhill <david(dot)bernhill(at)digitalroute(dot)com> |
---|---|
To: | Dave Cramer <Dave(at)micro-automation(dot)net> |
Cc: | pgsql-jdbc(at)postgresql(dot)org |
Subject: | Re: raw data broken in 7.2 driver? |
Date: | 2002-04-09 13:32:37 |
Message-ID: | 1018359157.15920.37.camel@puh.digitalroute.xx |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-jdbc |
Hi Dave.
No network issues. Everything is running on my machine (dual intel with
scsi and 512mb ram). Anyone else that has some figures of the raw data
performance?
regards David
> David,
>
> This is quite a difference? Are there any network differences that would
> account for the difference?
>
> Dave
> On Tue, 2002-04-09 at 08:50, David Bernhill wrote:
> > Hello Barry.
> >
> > Great! Thanks for your answer. Are there any documentation/discussion
> > concerning the performance of the jdbc driver for postgresql (or some
> > tuning parameters that can be of interest)? Are there any figures
> > related to "blob" performance? I takes me about 11 seconds to insert 1mb
> > raw data in postgresql, compared to 1.5 second in oracle. I tried the
> > bytea type as well, but the result was more or less the same.
> >
> > thanks, David
> >
> > > David,
> > >
> > > The behavior you are describing is correct for the 7.2 driver. In 7.2 the driver now uses the bytea datatype to store binary data (not largeobjects as it did in 7.1 and earlier). This is documented in the 7.2 documentation. Also in the doc is a description on how to revert back to the old behavior.
> > >
> > > Thanks,
> > > --Barry
> > > -----Original Message-----
> > > From: David Bernhill <david(dot)bernhill(at)digitalroute(dot)com>
> > > Date: 08 Apr 2002 13:03:15
> > > To: pgsql-jdbc(at)postgresql(dot)org
> > > Subject: [JDBC] raw data broken in 7.2 driver?
> > >
> > > Good day.
> > >
> > > I'm having problems inserting raw data with the 7.2 jdbc driver. I've
> > > tried out most of the ones available for download (Java 2). Some of them
> > > seem to work with raw data in 7.2 but has problems with timestamp
> > > instead. Is there any patch available for this?`For more detailed
> > > description see below (found in the interactive docs).
> > >
> > > Comment from Adam Jenkins "<adam(at)thejenkins(dot)org>":
> > > "The JDBC example given above as example 8-2 does not work as
> > > advertised. I'm using postgresql 7.2, and the jdbc7.2dev-1.2.jar JDBC
> > > driver. It seems that the driver interprets the data it reads from the
> > > InputStream passed to setBinaryStream as a binary representation of the
> > > actual field value -- in this case as a binary representation of an oid.
> > > This is of course incorrect; really the binary data is image data, and
> > > one would hope that what the driver would do is create a new large
> > > object, store the binary data in it, and store the oid of the large
> > > object in the oid field. What really happens is that the driver
> > > constructs a SQL statement which has the binary data which was read from
> > > the InputStream embedded directly in it as the value of the oid field.
> > > So executeUpdate throws a SQLException like this:
> > >
> > > java.sql.SQLException: ERROR: oidin: error in "213"
> > >
> > > regards David
> > >
> > >
> > >
> > > ---------------------------(end of broadcast)---------------------------
> > > TIP 5: Have you checked our extensive FAQ?
> > >
> > > http://www.postgresql.org/users-lounge/docs/faq.html
> >
> >
> >
> > ---------------------------(end of broadcast)---------------------------
> > TIP 2: you can get off all lists at once with the unregister command
> > (send "unregister YourEmailAddressHere" to majordomo(at)postgresql(dot)org)
> >
> >
>
>
From | Date | Subject | |
---|---|---|---|
Next Message | Barry Lind | 2002-04-09 15:58:39 | Re: raw data broken in 7.2 driver? |
Previous Message | Dave Cramer | 2002-04-09 13:16:00 | Re: raw data broken in 7.2 driver? |