You are not logged in.
Pages: 1
I'm trying to insert a object into a table and I get this error from the server:
"Too many : ( ) : params".
The table(class) that I'm trying to insert has 65 fields (published properties).
What could be the cause of this error?
Last edited by ManUn (2013-02-19 12:45:54)
Offline
At SynCommons.pas you have
MAX_SQLFIELDS = 64;
Change this value according to this text:
MAX_SQLFIELDS default is still 64, but can now be set to any value (64,
128, 192 and 256 have optimized fast code) so that you can have any number
of fields in a Table
"Uncertainty in science: There no doubt exist natural laws, but once this fine reason of ours was corrupted, it corrupted everything.", Blaise Pascal
Offline
Thank you for the answer, but, this is already in 128. Even If I change to 256 the error continues.
function ExtractInlineParameters(const SQL: RawUTF8;
var Types: TSQLParamTypeDynArray; var Values: TRawUTF8DynArray;
var maxParam: integer; var Nulls: TSQLFieldBits): RawUTF8;
var ppBeg: integer;
P, Gen: PUTF8Char;
wasNull: boolean;
begin
(...)
if maxParam>high(Types) then
raise ESynException.Create('Too many :(): params'); //<--- error occurs here
(...)
end;
Last edited by ManUn (2013-02-19 13:18:48)
Offline
This limitation should be removed now.
You can delete the whole check, since the Types[] array is now a dynamic array, resized within the internal loop.
Offline
Beautiful, thanks!!
Offline
Pages: 1