Page 1 of 1

SQL Error Bad handshake

Posted: 28.07.2007, 20:27
by riedere
Delphi 2007 Zeos 6.6.1 runns wonderfull for me...!
Delphi 5 prof Zeos 6.6.1 when I will activate the connection always

SQL Error Bad Handshake

It is mysql 5 ....

I have the same Parameters given like in Delphi 2007
(Delphi 5 and Delphi 2007 are on differrent PC's)

Any Ideas where should I have a look ?

Has this somethin to do with the ADO Components ?
These I have nor installed on Delphi 5 so during compiling the Zeos I had to remark these.

In this Procedures the shows the place where the Error ??
procedure CheckMySQLError(PlainDriver: IZMySQLPlainDriver;
Handle: PZMySQLConnect; LogCategory: TZLoggingCategory; const LogMessage: string);
var
ErrorMessage: string;
ErrorCode: Integer;
begin
ErrorMessage := Trim(StrPas(PlainDriver.GetLastError(Handle)));
ErrorCode := PlainDriver.GetLastErrorCode(Handle);
if (ErrorCode <> 0) and (ErrorMessage <> '') then
begin
if SilentMySQLError > 0 then
raise EZMySQLSilentException.CreateFmt(SSQLError1, [ErrorMessage]);

DriverManager.LogError(LogCategory, PlainDriver.GetProtocol, LogMessage,
ErrorCode, ErrorMessage);
*****this ist highlighted->>> raise EZSQLException.CreateWithCode(ErrorCode,
Format(SSQLError1, [ErrorMessage]));
end;
end;



Thanks Erich

Interesting Solution found..

Posted: 28.07.2007, 20:53
by riedere
Insteed the mysql5 Driver I choose the mysql4.1
and it works...
But the mysql Server on the host is 5.0.33
I work now with them

Erich

Posted: 29.07.2007, 21:14
by mdaems
Probably the old mysql4.1 dll is in the system path somewhere. If you copy the libmysql50.dll from zeoslib (or your mysql distribution) in the system path you should be able to use mysql 5 protocol.

Mark