Comment 14 for bug 1642344 (tji) wrote :

We deployed the fix and started to see issues.

Cloning process seems fine. Without updating anything the template can be saved.

When running reports from the cloned templates, there were errors complaining either lacking field in Group By or missing From clause.

When cloning the templates, removing then putting back the complained fields solved the issue.

It seems the issue is related to how the tables are joined. See the screenshot. Nearly all our templates starting from Item table leading to Call Number > Bib > Simple Record Exact are affected.

From Item table to Shelving Location or Copy Status tables sometimes have the issue, too.

Below is a sample error, which seems different. It complains of circ_lib in circulation table, which is used as a filter. The template simply counts circs based on the checkout library filtering on circ_lib (circ table), checkout time and checkout staff profile (we has special profile for selfcheck).

: DBD::Pg::st execute failed: ERROR: column "f45381a54504218e39aca33492d29306.circ_lib" must appear in the GROUP BY clause or be used in an aggregate function LINE 8: HAVING "f45381a54504218e39aca33492d29306"."circ_lib" IN ($... ^ at /srv/openils/bin/ line 255.

Running the report from these XUL templates has no issue.