Thanks Teh,

I'll give a try in the validation using specific validations, like
checking for unique key violations.
About the log, i already use that, what i was asking for is a way to
get an error message / error number from Cake, like, for example, the
mysql_error or mysql_errno if i were using the mysql libs.

And hou about an unexpected error? How to handle it and show it nicely
to the user? Any ideas?

Best regards,
Luiz Poleto

On May 23, 6:26 pm, Teh Treag <tehtr...@gmail.com> wrote:
> Luiz,
>
> Unique keys violation and stuff like that are issues that should occur
> during validation.  Check out the manual 
> -http://book.cakephp.org/view/125/Data-Validation
>
> As for logging it, you can use the log method (available in all
> classes which derive from Object) -http://api.cakephp.org/class/object
>
> -teh
>
> On May 23, 2:51 pm, Luiz Poleto <luiz.pol...@gmail.com> wrote:
>
> > Hello all,
>
> > I've been searching around, but i couldn't find the right directions for
> > error handling using cake.
>
> > For example, i would like to treat errors from database, like unique keys
> > violation and sutff like that. Also, any other errors that would happen
> > would be nice to treat and log it with information like the error number and
> > error message when it comes to database errors.
>
> > Does anybody can point me the right way of doing that?
>
> > Thanks,
> > Luiz Poleto
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to 
cake-php+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to