[Gambas-user] Probable bug in Postgres db driver
richard terry
rterry at ...1946...
Wed Feb 25 21:49:00 CET 2009
I've posted about this before in regards to the PictureDatabase example, as in
postgres though you can save the picture, it dosn't retreive. I had asked
someone to test it, though no-one appears to have had the time.
This driver is pretty critical to my medical records project, as I used to be
able to save images of skin lesions/Xrays, diagrams, line drawings, back to
my database and now can save but the retreived image is chopped losing a
number of bytes from the end and won't display.
I want to be able to present my program at a medical computing conference in
July as a prototype version reasonably fully complete by then, so I need it
to work. All this work of mine by the way will be open-sourced if I can get
it to a state of functional completeness.
So I asked my mate Ian Haywood, who is quite an accomplished programmer and
far far brighter and more computer literate than I by sending him this
message
> If you updated the latest gambas - you don't need my program to test this -
> just change a couple of lines of code in the picturedatabase sample program
> to use postgres and you will see the error. Maybe, it is only on my machine.
and this was his reply:
=================================================
I can reproduce this. It is only postgres, only gambas, and only with the
BYTEA type, TEXT doesn't do this (but you can't put a png in text, at least
not easily).
So, it's definitely a bug in the postgres drivers for gambas.
Has this been reported to the gambas list?
There is a workaround: convert the png to text and store, then convert back on
reading. this works b/c our images are small, but big images will waste space
and cause slowness. this solution is fairly easy to whip up, I can do this if
the underlying bug can't be fixed and we want this functionality for
10240cc[conference].
Ian
=================================================
So I wondered if somone could test the postgres driver again, just to make
sure it is not a library on my machine, although I know Ian runs a debian
flavour so probably not.
Regards
Richard
-------------- next part --------------
An embedded message was scrubbed...
From: Ian Haywood <ihaywood at ...1979...>
Subject: Re: Ok, This you could help with
Date: Wed, 25 Feb 2009 23:14:15 +1100
Size: 1800
URL: <http://lists.gambas-basic.org/pipermail/user/attachments/20090226/d892aae8/attachment.mht>
More information about the User
mailing list