Forums

Unknown 'Array' in 'where clause': it makes no sense

kgriffin 30 Oct, 2020
Okay. I am stumped. I have a simple where clause using a field in the table I am reading called userid and setting it equal to {user:id} and am getting the array error for the where clause. This is very puzzling. What do I need to do to fix this?
kgriffin 30 Oct, 2020
Update: I broke down the form into its separate pages. I eliminated the where clause on the page where it was used, and still got the same error. Then I got rid of the Read Data action all together. Still got the same error.

Not sure what is happening here?
kgriffin 31 Oct, 2020
Answer
Urg. Okay. Every time one makes a change in Actions, one must not just empty the cache in Chronoforms, but also your browser, or you are stuck in this ridiculous situation. Sometimes you have to delete the Actions altogether, save the form, THEN empty both caches, and then redo your Actions.

Also: the issue with the WHERE clause was tripped when I included 'Populate Fields' and one of my field names had a stray letter in it.

Just in case anyone else gets stumped.
Max_admin 02 Nov, 2020
If one of your Where conditions is getting an array then you should use IN but not equal, I'm not sure how this error occured, maybe you can provide more info so I can check it!
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
You need to login to be able to post a reply.