what im doing wrong? _utf8 :parameter

Discussion of open issues, suggestions and bugs regarding MyDAC (Data Access Components for MySQL) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
Frega
Posts: 8
Joined: Thu 23 Apr 2009 18:44

what im doing wrong? _utf8 :parameter

Post by Frega » Mon 13 Jul 2009 18:56

Hello, im having some trouble with a case insensitive login...

look the SQL query code:
select * from s_users where user = _utf8 :user and pass = :pass

Example:
user: Admin
pass: root

in the sql manager i put this code:
select * from s_users where user = _utf8 'ADMIN' and pass = 'root'
Works fine, the user 'Admin' is found


but in runtime with parameters does not work,

qLOGIN.parambyname('user').Value := edtLogin.text;
qLOGIN.parambyname('pass').Value := edtPass.text;
qLOGIN.Open;

just returns a empty dataset... only works if i use a case sensitive user name, like 'Admin' not 'ADMIN' or 'admin'


what is the problem?

Thanks,

Challenger
Devart Team
Posts: 925
Joined: Thu 17 Nov 2005 10:53

Post by Challenger » Wed 15 Jul 2009 11:33

We could not reproduce the problem. Please try to execute this query without parameters using MyDAC.

Frega
Posts: 8
Joined: Thu 23 Apr 2009 18:44

Post by Frega » Thu 16 Jul 2009 17:30

oh, sorry, its my mitake...

working fine now :D

thanks

Post Reply