Hi,
After I installed MyDac with Delphi and MySQL 5, I received new error. This error is : MyDac always return LargInt value when I use MySQL alias. After to try different way, change Delphi vcl, update MySQL..... I find one solution to resolve the problem.
My solution have two restrictions to work
1: You need MySQL 5 or more
2: Your value doesn't exceed "9 999 999 999" value
So, I'll explain how we can resolve the problem. This is very simple but you have to think about it. we need to create a new function to return Int(9). This is my SQL query like this.
CREATE FUNCTION INTCAST(param INTEGER) RETURNS INT(9) DETERMINISTIC
BEGIN
RETURN param;
END
After this we can call this functin like this in SQL query
Select INTCAST(0) AS TOT
If you use this, MyDac alway return Integer value in delphi and the problem is resolve
Guillaume Corneau