Op 07-08-2023 om 18:32 schreef paste...@gmx.com:
Buffer := 'show databases;';
writeln(Buffer);
buffer := Buf2Hex(buffer);
Buffer := #03 + Buffer + #0; // #03 com_query header    #0 <eof>
writeln(Buffer);
sock.sendstring(buffer);
BTW you missed the length here.
I have:

Buffer := Command + SQL;
Buffer := chr(length(buffer)) + #0#0 { len 3 bytes } + #0 { packnum } + Buffer;

Although the first 3 bytes should be the length but here I have max 255 because I only use the first byte;
That should be different if you get larger SQL's.

Grtz,
Rik
_______________________________________________
synalist-public mailing list
synalist-public@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/synalist-public

Reply via email to