PostgreSQL and array

Discussion of open issues, suggestions and bugs regarding UniDAC (Universal Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
banita
Posts: 29
Joined: Fri 19 Jun 2009 14:31

PostgreSQL and array

Post by banita » Sat 15 Aug 2009 22:31

I hava table with integer array field.
How can I do query like this:

select tab[1:3] from xxx;

?

I set ParamCheck on false but TUniQUery always interpret '3' like a param.


sory for my english.

Plash
Devart Team
Posts: 2844
Joined: Wed 10 May 2006 07:09

Post by Plash » Tue 18 Aug 2009 06:59

Try to add a space after ':'

Code: Select all

select tab[1 : 3] from xxx

banita
Posts: 29
Joined: Fri 19 Jun 2009 14:31

Post by banita » Tue 18 Aug 2009 11:47

Unfortunately I get error:
"syntax error at or near 3"

When I try this query in PgAdmin all works fine.
strange...

Plash
Devart Team
Posts: 2844
Joined: Wed 10 May 2006 07:09

Post by Plash » Wed 19 Aug 2009 07:43

We will add support for executing such query with spaces in the next build of PgDAC.

Post Reply