Hi all!
first of all let me say a huge Thank You to all developers of ZeosLib!!!
I'm coding a database application after a few years without writing a single line of code, and couldn't belive my eyes when found ZeosLib!
Is is absolutely amazing, native acces to SQL engines... for FREE!!!
thanks a lot guys this is really exciting!
ok, let me introduce my problem
I would like to know how can one handle EZSQLExceptions elegantly. I mean, I wouldn't like to show the user an english error message (users will be spanish people), and also, I would like to give a more detailed explanation of what is going wrong.
I guess one needs to work with ErrorCode and StatusCode properties, but how can one know what those numbers mean?
I'm working with Delphi 7 + MySQL 5 + ZeosLib 6.6.1-beta.
thanks,
Juan Ortanobas
How to handle EZSQLExceptions
Moderators: gto, cipto_kh, EgonHugeist
- mdaems
- Zeos Project Manager
- Posts: 2766
- Joined: 20.09.2005, 15:28
- Location: Brussels, Belgium
- Contact:
Hi Juan,
Meanings of the codes sent by mysql are explained in Appendix B of the mysql documentation.
The message that goes with the code is also available in your exception. (see the CheckMySQLError procedure in zdbcmysqlutils.pas)
I hope you find out how to get zeoslib messages in spanish? Edit zeos.inc : {$DEFINE SPANISH} instead of {$DEFINE ENGLISH} Messages come from Messages.pas unit.
Mark
Meanings of the codes sent by mysql are explained in Appendix B of the mysql documentation.
The message that goes with the code is also available in your exception. (see the CheckMySQLError procedure in zdbcmysqlutils.pas)
I hope you find out how to get zeoslib messages in spanish? Edit zeos.inc : {$DEFINE SPANISH} instead of {$DEFINE ENGLISH} Messages come from Messages.pas unit.
Mark