⚠ In case you've missed it, we have migrated to our new website, with a brand new forum. For more details about the migration you can read our blog post for website migration. This is an archived forum. ⚠

  •     

profile picture

How to know if update/insert/delete fails?



NachoIF

NachoIF
  • profile picture
  • Member

Posted 22 December 2014 - 17:03 PM

Hello everybody
 
here is my first message in the forum, hope you can help me.
 
is possible to determine if an insert or update fails becouse a foreing key? is there any status code or something similar to know that?
 
For example, when i try to delete a row that contains a foreign key in other table, grocery crud seems not doing nothing and no kind of message is showed about that.
 
How can i prevent that? or in other case, how can i control that?
 

 

P.D Sorry about my english....


NachoIF

NachoIF
  • profile picture
  • Member

Posted 28 December 2014 - 21:43 PM

after one week no reply.

 

anyone ever had this problem?


Dogtooth

Dogtooth
  • profile picture
  • Member

Posted 26 January 2015 - 20:38 PM

I have the same problem. Some kind of solution would be really appreciated.


Amit Shah

Amit Shah
  • profile picture
  • Member

Posted 27 January 2015 - 07:19 AM

well.. if insert / update / delete fails ... it might fail to show up any message... and wont proceed further.. rather return the control back or keep on hanging.

1 reason for it not able to control - is it fails to generate that error message. This is possible if codeigniter is in production mode - meaning the error reporting is turned off...if so - change the mode to development mode and u will see the error / issue.

2. in case if any error or anything - go back and check in the response in firebug ( i recommend developers use firefox with firebug installed) ... there if any error has shooted up - it will show up.

3. Try to identify if any error have been registered in the error log file ... that way too will be able to know if anything have failed and for what reason.

 

Grocerycrud - yes is not looking in for foreign key management... so what i will recommend is .. u can take up the callback action - write your own code to manage the same.

 

Happy GCing :)