Hi, when I try to access node/*/registrations, I get this error:
PDOException: SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '))' at line 1: SELECT sum(count) AS count FROM {registration} r WHERE (entity_id = :db_condition_placeholder_0) AND (entity_type = :db_condition_placeholder_1) AND (state IN ()) ; Array ( [:db_condition_placeholder_0] => 2000 [:db_condition_placeholder_1] => node ) in function registration_event_count() (Line: 614 in file /mysite/sites/all/modules/registration/registration.module).
I am using Registration 7.x-1.0-beta3 and Entity 7.x-1.x-dev.
Comments
Comment #1
SocialNicheGuru CreditAttribution: SocialNicheGuru commentedI just got this to at the same url node/*/registrations
Comment #2
levelos CreditAttribution: levelos commentedLooks like you guys have don't have any states defined for the registrations. Maybe an upgrade path issue?
Comment #3
garpy CreditAttribution: garpy commentedDon't know if this will help anyone but after getting a PDO exception changing the memory limit and restarting mysql everything worked. Cheers
I also used a dev version from (8/2/12 11:00 AM) instead of the one from July 20 on D.O.
Comment #4
SocialNicheGuru CreditAttribution: SocialNicheGuru commentedyou were right #2
Comment #5
Kebz CreditAttribution: Kebz commentedThis is popping up in my log messages and I have no clue what's generating it.
This does not happen to me, so I have no idea how to generate this error at all. I wish I could so that I can get the "backtrace" info.
Comment #6
caxy4 CreditAttribution: caxy4 commented@Kebz - did you upgrade the module or install fresh?
It's likely you don't have registration states defined as @levelos suggests in comment #2.
I asked if you upgraded or installed fresh because having no registration types for an existing registration sounds like it could only be caused by a faulty upgrade.
Comment #7
Kebz CreditAttribution: Kebz commentedHi @caxy4
By "registration states" ... you mean the ones located here? "admin/structure/registration/registration_states"
I also have lots of "registration types" that I've created months ago and located on this path "admin/structure/registration/registration_types"
Regarding the "upgrade" .... I just noticed that there's a new upgrade to this module after I read your message.
I upgraded both of my sites. I'll wait a day to report back if I see that error on my message logs.
Thanks =)
Comment #8
Kebz CreditAttribution: Kebz commentedokay... it didn't take long for the error to pop up on both of my sites
The "referrer" or "location" from the details of the message is coming from the root directory or an article.
Why would this error pop up on the message log if an anonymous user is browsing the site??
Comment #10
caxy4 CreditAttribution: caxy4 commented@Kebz, I've found a few vulnerabilities in the code that may have caused the error you saw in the log.
I've fixed the vulnerability with commits b8b46cd and 4b89be6. Try using the latest version of the 7.x-1.x-dev branch and let me know if you still get the message.
In fact the commits referenced above should take care of this issue generally. Closing as fixed.
Comment #11
Kebz CreditAttribution: Kebz commented@caxy4 - thank you!
I upgraded to the latest and so far so good =)