>David,
>
>I had a similar problem with Sybase, I read on technet somewhere to create your SQL statement in chunks (seperate variables) then concatenate as below:-
>
>sql1="Select * "
>sql2="FROM adatabase "
>sql3="WHERE x=123 "
>
>fullsql=sql1+sql2+sql3
>
>This works great for me, hope this helps you
>
>Alec Dearden.
Thanks for the suggestion,
Unfortunately, this is what I am already doing, and it stops working when "fullsql" exceeds 30,000 bytes in length.
David,