How to execute a SQL statement greater than 64K

By: CodeGear

Abstract: Using DbiQExecDirect instead of a TQuery will allow a query longer than 64K

Question:
I've found that a TQuery has a limit of 64K for its SQL statement. Can I execute a SQL statement that is longer?
Answer:
You can do this by calling DbiQExecDirect. The following example assumes you have BDE and DBtables in your uses clause.

var
QryStr : String;
begin
//Assign QryStr here
Check(DbiQExecDirect(Database1.Handle, qrylangSQL, PChar(QryStr), nil));
end;


Server Response from: ETNASC04