SymQL
Symphony Query Language
Pending#1: Pagination problems
Could you try:
var_dump(SymQL::getDebug());die;
This should dump out the JOIN and WHERE strings SymQL is creating. Sounds a bit like this hack isn’t working perhaps.
While my data source returns the correct entries the pagination goes mad as it return the following information
Are you 100% sure the entries are correct but pagination not? SymQL doesn’t do anything clever with pagination values, it just gets them from the EntryManager. So if there’s a bug with this, it sounds like it could be with EntryManager.
From what I understand there is a long running bug with the Taglist field that I think is causing this issue, not SymQL.
Brendan, do you know where this bug is caused inside the taglist field?
This is how the debug looks like:
Array ( [queries] => Array ( [Resolve section and fields] => 0 [Fetch entries] => 2 [Total] => 2 ) [sql] => Array ( [joins] => LEFT JOIN `sym_entries_data_13` AS t13_1 ON (e.id = t13_1.entry_id) LEFT JOIN `sym_entries_data_14` AS t14_1 ON (e.id = t14_1.entry_id) LEFT JOIN `sym_entries_data_18` AS t18_3 ON (e.id = t18_3.entry_id) [where] => AND ( t13_1.value IN ('calendar') OR t13_1.handle IN ('calendar') ) OR ( t14_1.value IN ('calendar') OR t14_1.handle IN ('calendar') ) AND ( t18_3.value IN ('Nils') OR t18_3.handle IN ('Nils') ) ) )
The resulting variable $where
returns this:
AND ( t37_1.value IN ('Nils') OR t37_1.handle IN ('Nils') ) AND ( t18_1.value IN ('Texte') OR t18_1.handle IN ('Texte') )
The resulting variable $where
returns this:
AND ( t37_1.value IN ('Nils') OR t37_1.handle IN ('Nils') ) AND ( t18_1.value IN ('Texte') OR t18_1.handle IN ('Texte') )
Sorry - the edit function seems to be broken …
Brendan, could you elaborate on the Taglist bug please? Haven’t come across that one before.
To be closed.
I’m using this extension to build some custom data sources. In this case I’m trying to fetch entries that match the following conditions:
deutsche-tags
) OR English tags (englische-tags
)bereich
).While my data source returns the correct entries the pagination goes mad as it return the following information
This would be the correct information:
I suppose the wrong entry count is a result of tags with the same name in the German and the English list but I’m not sure. Any idea how/where to fix this?
This is how the
grab()
function of my data source looks like: