Board index » delphi » Retrieving CLOB Field from Oracle DB

Retrieving CLOB Field from Oracle DB

Hi,

I'm trying to retrieve a CLOB field from an Oracle DB.
However, everytime I go to open my query, I get the following error:
   ...EDBEngineError with message 'General SQL error.  Restricted datatype attribute violation'...

I have deduced that it is my CLOB field in the table which is causing this.  My query is simply
   'select * from hal.address';

If I do a select specifically against the CLOB field ie:
   'select addr from hal.address'
I get an error (EDBEngineError) saying invalid field type...

I can insert information fine into it...

Any help would be most appreciative...

Jason

ps...I just use the field to store basically lines from a memo...ie no graphics etc...

 

Re:Retrieving CLOB Field from Oracle DB


Oracle, Delphi versions?

regards,
Martin

Re:Retrieving CLOB Field from Oracle DB


Wich can of datatype is bounded to the CLOB field ?

"Jason Smart" <jason.sm...@au.unisys.com> escribi en el mensaje
news:3b1c959b$1_1@dnews...

Quote

> Hi,

> I'm trying to retrieve a CLOB field from an Oracle DB.
> However, everytime I go to open my query, I get the following error:
>    ...EDBEngineError with message 'General SQL error.  Restricted datatype

attribute violation'...
Quote

> I have deduced that it is my CLOB field in the table which is causing

this.  My query is simply
Quote
>    'select * from hal.address';

> If I do a select specifically against the CLOB field ie:
>    'select addr from hal.address'
> I get an error (EDBEngineError) saying invalid field type...

> I can insert information fine into it...

> Any help would be most appreciative...

> Jason

> ps...I just use the field to store basically lines from a memo...ie no

graphics etc...

Re:Retrieving CLOB Field from Oracle DB


Quote
"Martin Brekhof" <m.brek...@home.nl> wrote:
>Oracle, Delphi versions?

>regards,
>Martin

Hi,

Yeah good point...sorry!
I'm using D5 Pro with Oracle 8i...
And I am using the Oracle ODBC drivers (v8.00.03.00)
I should also point out that I get the error when I open the query, (ie query1.open) not when I'm trying to extract the info from the query.

If I use Oralce SQL*Plus I can see the results of the table fine so I know there is data in there too...Not that that would necessarily cause the problem..

Hope this helps...

Jason

Re:Retrieving CLOB Field from Oracle DB


If you are using ADO Express... I had a similar problem but I was using
BLOB, it seems like is not supported.... (not sure)
I had to use DOA (Direct Oracle Acces), which happens to be a very nice set
of components that meke your life a lot easier...

you can get it at http://www.allroundautomations.nl/downloads.html

hope that helps.

Quote
"Jason Smart" <jason.sm...@au.unisys.com> wrote in message

news:3b1d5ccb$1_2@dnews...
Quote

> "Martin Brekhof" <m.brek...@home.nl> wrote:
> >Oracle, Delphi versions?

> >regards,
> >Martin

> Hi,

> Yeah good point...sorry!
> I'm using D5 Pro with Oracle 8i...
> And I am using the Oracle ODBC drivers (v8.00.03.00)
> I should also point out that I get the error when I open the query, (ie

query1.open) not when I'm trying to extract the info from the query.
Quote

> If I use Oralce SQL*Plus I can see the results of the table fine so I know

there is data in there too...Not that that would necessarily cause the
problem..
Quote

> Hope this helps...

> Jason

Re:Retrieving CLOB Field from Oracle DB


I'm not using ADO express as I only have D5 Pro...
I have DOA but since I don't wish to pay for the components I only have the limited download trial version.

Can anyone confirm whether BLOB/CLOB fields are supported...
D5 Pro, Oracle 8, Oracle ODBC Drivers...

Cheers

Jason

Quote
"Pancho" <do...@nowhere.com> wrote:
>If you are using ADO Express... I had a similar problem but I was using
>BLOB, it seems like is not supported.... (not sure)
>I had to use DOA (Direct Oracle Acces), which happens to be a very nice set
>of components that meke your life a lot easier...

>you can get it at http://www.allroundautomations.nl/downloads.html

>hope that helps.

>"Jason Smart" <jason.sm...@au.unisys.com> wrote in message
>news:3b1d5ccb$1_2@dnews...

>> "Martin Brekhof" <m.brek...@home.nl> wrote:
>> >Oracle, Delphi versions?

>> >regards,
>> >Martin

Re:Retrieving CLOB Field from Oracle DB


If you are using the Delphi componets, TTable or TQuery... you shouldn't
have any problems...
I have a little app that loads images into my Db..

To load I only put my query in insert mode and then load the file..

query1.Insert;
query1imag.LoadFromFile('c:\logo.bmp');
query1.Post;

I have no problems once so ever on the select statements...
Sorry I can't be of any more help..

Good luck.

Quote
"Jason Smart" <jason.sm...@au.unisys.com> wrote in message

news:3b1eaf65$2_2@dnews...
Quote

> I'm not using ADO express as I only have D5 Pro...
> I have DOA but since I don't wish to pay for the components I only have

the limited download trial version.
Quote

> Can anyone confirm whether BLOB/CLOB fields are supported...
> D5 Pro, Oracle 8, Oracle ODBC Drivers...

> Cheers

> Jason

> "Pancho" <do...@nowhere.com> wrote:
> >If you are using ADO Express... I had a similar problem but I was using
> >BLOB, it seems like is not supported.... (not sure)
> >I had to use DOA (Direct Oracle Acces), which happens to be a very nice
set
> >of components that meke your life a lot easier...

> >you can get it at http://www.allroundautomations.nl/downloads.html

> >hope that helps.

> >"Jason Smart" <jason.sm...@au.unisys.com> wrote in message
> >news:3b1d5ccb$1_2@dnews...

> >> "Martin Brekhof" <m.brek...@home.nl> wrote:
> >> >Oracle, Delphi versions?

> >> >regards,
> >> >Martin

Other Threads