error TZReadOnlyQuery with MYsql Variables in Delphi5

Forum related to version 6.5.1 (alpha) and 6.6.x (beta) of ZeosLib's DBOs

Moderators: gto, cipto_kh, EgonHugeist

Post Reply
KAYAALP
Fresh Boarder
Fresh Boarder
Posts: 4
Joined: 18.09.2007, 09:49

error TZReadOnlyQuery with MYsql Variables in Delphi5

Post by KAYAALP »

hello everybody,
i want to execute this sql (MySql 4.0x) with TZReadOnlyQuery id Delphi5

SELECT @n := @n+1 AS rownum, thing, arms, legs FROM limbs

but i get this error : "incorrect token followed by ':'"

i think that, the sql parser looks for a parameter after the ':'
how can i solve the problem?
User avatar
dhongu
Junior Boarder
Junior Boarder
Posts: 37
Joined: 28.09.2005, 08:37
Location: Bucuresti
Contact:

Post by dhongu »

SELECT @n ::= @n+1 AS rownum, thing, arms, legs FROM limbs

or set checkparam = false in property of component (TZReadOnlyQuery)
Dorin Hongu
KAYAALP
Fresh Boarder
Fresh Boarder
Posts: 4
Joined: 18.09.2007, 09:49

Post by KAYAALP »

thank you so much
railgun3r
Fresh Boarder
Fresh Boarder
Posts: 9
Joined: 03.05.2011, 19:20

Re: error TZReadOnlyQuery with MYsql Variables in Delphi5

Post by railgun3r »

KAYAALP wrote: SELECT @n ::= @n+1 AS rownum, thing, arms, legs FROM limbs
Its not working in delphi 7, mysql 5.1 and zeos 6.6.6
how to use it in delphi 7?

or set checkparam = false in property of component (TZReadOnlyQuery)
I can't do this. cuz I have another params in query also.

could somebody help?
User avatar
mdaems
Zeos Project Manager
Zeos Project Manager
Posts: 2766
Joined: 20.09.2005, 15:28
Location: Brussels, Belgium
Contact:

Post by mdaems »

I'm afraid I only have a solution in zeos7 : there you can set another parameter character instead of ':'

Mark
Image
Post Reply