Bug #5092
closedCBSubs URL filter in payment center causing SQL error
100%
Description
Unsure if issue is in CBLib or CBSubs at this time. Clicking New Registrations, Upgrades, or Renewals in the payment center will cause the below.
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 '= '1' )' at line 2 SQL=SELECT COUNT FROM `jos_cbsubs_payments` AS a WHERE ( a.`time_paid_date` = '2015-01-12' ) AND ( (.`upgrades` = '1' )
The query seams to be broken. First it's missing "a" table as and second it has an extra bracket.
Updated by krileon about 9 years ago
Seams like this is maybe a bug in CBSubs XML as the view.showpayments.xml view has the below for the filter.
<filter name="upgrades" type="field_show_only_if_selected" base="xml:yesno" size="1" default="" label="Upgrades only" blanktext="--- By Upgrades ---" description="Select if you want to show payments for upgrades only">
<data name="upgrades">
<joinkeys type="inner" />
</data>
</filter>
The data doesn't make any sense.
Updated by beat about 9 years ago
- Target version changed from CB 2.0.6 to CB 2.0.7
Updated by beat about 9 years ago
- Target version changed from CB 2.0.7 to CB 2.0.8
Updated by krileon about 9 years ago
- Status changed from Assigned to Rejected
- Target version deleted (
CB 2.0.8) - % Done changed from 0 to 100
This filter never worked. I've reverted to old code and it never did anything. It just previously did not error. The reason it doesn't do anything is the filter has no join. The join it's trying to use doesn't exist, because the usage is a subquery only, which can't function in a COUNT. The filter needs fixed in CBSubs it self.