Error while reading a blob field
Posted: Wed 15 Jul 2009 08:31
I have this table in postgresql :
CREATE TABLE sif_pictogrami
(
id serial NOT NULL,
picture oid,
naziv character varying(100)
)
WITH (OIDS=FALSE);
ALTER TABLE sif_pictogrami OWNER TO postgres;
I use this UniQuery "select * from sif_pictogrami" to open a table and give me error active trasaction is required for operation for large objects. to insert a picture i use
'INSERT INTO sif_pictogrami (picture) VALUES(lo_import(' + '''' + FileName + '''' + '));'
this query and i have no problem. I also try the example from C:\Program Files\Devart\UniDac for Delphi 7\Demos\UniDacDemo\Pictures but that example does not store the picture in the data base only load from the file and when i try to POST give me the same error.
Any help how can i store, view data in oid field from Delphi 7.
CREATE TABLE sif_pictogrami
(
id serial NOT NULL,
picture oid,
naziv character varying(100)
)
WITH (OIDS=FALSE);
ALTER TABLE sif_pictogrami OWNER TO postgres;
I use this UniQuery "select * from sif_pictogrami" to open a table and give me error active trasaction is required for operation for large objects. to insert a picture i use
'INSERT INTO sif_pictogrami (picture) VALUES(lo_import(' + '''' + FileName + '''' + '));'
this query and i have no problem. I also try the example from C:\Program Files\Devart\UniDac for Delphi 7\Demos\UniDacDemo\Pictures but that example does not store the picture in the data base only load from the file and when i try to POST give me the same error.
Any help how can i store, view data in oid field from Delphi 7.