The following errors are being received on the Custom Sales Summary screen at admin/store/reports/sales/custom.

    * warning: pg_query() [function.pg-query]: Query failed: ERROR: column "uc_order_statuses.title" must appear in the GROUP BY clause or be used in an aggregate function in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 126.
    * user warning: query: SELECT COUNT(*) as count, title FROM uc_orders LEFT JOIN uc_order_statuses ON order_status_id = order_status WHERE 1172725200 <= created AND created <= 1175403599 AND order_status IN ('completed') GROUP BY order_status ORDER BY weight ASC in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 145.
    * warning: pg_query() [function.pg-query]: Query failed: ERROR: column "uc_order_statuses.title" must appear in the GROUP BY clause or be used in an aggregate function in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 126.
    * user warning: query: SELECT COUNT(*) as count, title FROM uc_orders LEFT JOIN uc_order_statuses ON order_status_id = order_status WHERE 1175403600 <= created AND created <= 1177995599 AND order_status IN ('completed') GROUP BY order_status ORDER BY weight ASC in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 145.
    * warning: pg_query() [function.pg-query]: Query failed: ERROR: column "uc_order_statuses.title" must appear in the GROUP BY clause or be used in an aggregate function in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 126.
    * user warning: query: SELECT COUNT(*) as count, title FROM uc_orders LEFT JOIN uc_order_statuses ON order_status_id = order_status WHERE 1177995600 <= created AND created <= 1180673999 AND order_status IN ('completed') GROUP BY order_status ORDER BY weight ASC in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 145.
    * warning: pg_query() [function.pg-query]: Query failed: ERROR: column "uc_order_statuses.title" must appear in the GROUP BY clause or be used in an aggregate function in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 126.
    * user warning: query: SELECT COUNT(*) as count, title FROM uc_orders LEFT JOIN uc_order_statuses ON order_status_id = order_status WHERE 1180674000 <= created AND created <= 1183265999 AND order_status IN ('completed') GROUP BY order_status ORDER BY weight ASC in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 145.
    * warning: pg_query() [function.pg-query]: Query failed: ERROR: column "uc_order_statuses.title" must appear in the GROUP BY clause or be used in an aggregate function in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 126.
    * user warning: query: SELECT COUNT(*) as count, title FROM uc_orders LEFT JOIN uc_order_statuses ON order_status_id = order_status WHERE 1183266000 <= created AND created <= 1185944399 AND order_status IN ('completed') GROUP BY order_status ORDER BY weight ASC in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 145.
    * warning: pg_query() [function.pg-query]: Query failed: ERROR: column "uc_order_statuses.title" must appear in the GROUP BY clause or be used in an aggregate function in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 126.
    * user warning: query: SELECT COUNT(*) as count, title FROM uc_orders LEFT JOIN uc_order_statuses ON order_status_id = order_status WHERE 1185944400 <= created AND created <= 1188622799 AND order_status IN ('completed') GROUP BY order_status ORDER BY weight ASC in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 145.
    * warning: pg_query() [function.pg-query]: Query failed: ERROR: column "uc_order_statuses.title" must appear in the GROUP BY clause or be used in an aggregate function in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 126.
    * user warning: query: SELECT COUNT(*) as count, title FROM uc_orders LEFT JOIN uc_order_statuses ON order_status_id = order_status WHERE 1188622800 <= created AND created <= 1191214799 AND order_status IN ('completed') GROUP BY order_status ORDER BY weight ASC in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 145.
    * warning: pg_query() [function.pg-query]: Query failed: ERROR: column "uc_order_statuses.title" must appear in the GROUP BY clause or be used in an aggregate function in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 126.
    * user warning: query: SELECT COUNT(*) as count, title FROM uc_orders LEFT JOIN uc_order_statuses ON order_status_id = order_status WHERE 1191214800 <= created AND created <= 1193893199 AND order_status IN ('completed') GROUP BY order_status ORDER BY weight ASC in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 145.
    * warning: pg_query() [function.pg-query]: Query failed: ERROR: column "uc_order_statuses.title" must appear in the GROUP BY clause or be used in an aggregate function in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 126.
    * user warning: query: SELECT COUNT(*) as count, title FROM uc_orders LEFT JOIN uc_order_statuses ON order_status_id = order_status WHERE 1193893200 <= created AND created <= 1196485199 AND order_status IN ('completed') GROUP BY order_status ORDER BY weight ASC in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 145.
    * warning: pg_query() [function.pg-query]: Query failed: ERROR: column "uc_order_statuses.title" must appear in the GROUP BY clause or be used in an aggregate function in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 126.
    * user warning: query: SELECT COUNT(*) as count, title FROM uc_orders LEFT JOIN uc_order_statuses ON order_status_id = order_status WHERE 1196485200 <= created AND created <= 1199163599 AND order_status IN ('completed') GROUP BY order_status ORDER BY weight ASC in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 145.
    * warning: pg_query() [function.pg-query]: Query failed: ERROR: column "uc_order_statuses.title" must appear in the GROUP BY clause or be used in an aggregate function in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 126.
    * user warning: query: SELECT COUNT(*) as count, title FROM uc_orders LEFT JOIN uc_order_statuses ON order_status_id = order_status WHERE 1199163600 <= created AND created <= 1201841999 AND order_status IN ('completed') GROUP BY order_status ORDER BY weight ASC in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 145.
    * warning: pg_query() [function.pg-query]: Query failed: ERROR: column "uc_order_statuses.title" must appear in the GROUP BY clause or be used in an aggregate function in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 126.
    * user warning: query: SELECT COUNT(*) as count, title FROM uc_orders LEFT JOIN uc_order_statuses ON order_status_id = order_status WHERE 1201842000 <= created AND created <= 1204347599 AND order_status IN ('completed') GROUP BY order_status ORDER BY weight ASC in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 145.
CommentFileSizeAuthor
#3 CustomSalesSummary.JPG204.07 KBWISEOZ

Comments

rszrama’s picture

Title: ERROR: column "uc_order_statuses.title" ... on Custom Sales Summary » PostgreSQL ERROR: column "uc_order_statuses.title" ... on Custom Sales Summary

I have no clue which query to look at here. Will need a pgsql dude to check it out.

japerry’s picture

I can't seem to duplicate this problem. I'm using the bzr release from March 22nd. I'd try getting a snapshot of from bazaar.ubercart.org and see if you still get the error

WISEOZ’s picture

StatusFileSize
new204.07 KB

Interestingly enough, I am also on the 3/22 bazaar version.

I've checked this report and the error has actually changed. It is now ...

    * warning: pg_query() [function.pg-query]: Query failed: ERROR: syntax error at or near "=" LINE 1: ...er_status_id = order_status WHERE 1172721600 < = created ... ^ in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 126.
    * user warning: query: SELECT COUNT(*) as count, title FROM uc_orders LEFT JOIN uc_order_statuses ON order_status_id = order_status WHERE 1172721600 < = created AND created <= 1175140799 AND order_status IN ('cancelled', 'in_checkout', 'pending', 'paypal_pending', 'processing', 'completed') GROUP BY uc_order_statuses.title ORDER BY weight ASC in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 145.
    * warning: pg_query() [function.pg-query]: Query failed: ERROR: syntax error at or near "=" LINE 1: ...er_status_id = order_status WHERE 1175140800 < = created ... ^ in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 126.
    * user warning: query: SELECT COUNT(*) as count, title FROM uc_orders LEFT JOIN uc_order_statuses ON order_status_id = order_status WHERE 1175140800 < = created AND created <= 1177819199 AND order_status IN ('cancelled', 'in_checkout', 'pending', 'paypal_pending', 'processing', 'completed') GROUP BY uc_order_statuses.title ORDER BY weight ASC in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 145.
    * warning: pg_query() [function.pg-query]: Query failed: ERROR: syntax error at or near "=" LINE 1: ...er_status_id = order_status WHERE 1177819200 < = created ... ^ in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 126.
    * user warning: query: SELECT COUNT(*) as count, title FROM uc_orders LEFT JOIN uc_order_statuses ON order_status_id = order_status WHERE 1177819200 < = created AND created <= 1180411199 AND order_status IN ('cancelled', 'in_checkout', 'pending', 'paypal_pending', 'processing', 'completed') GROUP BY uc_order_statuses.title ORDER BY weight ASC in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 145.
    * warning: pg_query() [function.pg-query]: Query failed: ERROR: syntax error at or near "=" LINE 1: ...er_status_id = order_status WHERE 1180411200 < = created ... ^ in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 126.
    * user warning: query: SELECT COUNT(*) as count, title FROM uc_orders LEFT JOIN uc_order_statuses ON order_status_id = order_status WHERE 1180411200 < = created AND created <= 1183089599 AND order_status IN ('cancelled', 'in_checkout', 'pending', 'paypal_pending', 'processing', 'completed') GROUP BY uc_order_statuses.title ORDER BY weight ASC in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 145.
    * warning: pg_query() [function.pg-query]: Query failed: ERROR: syntax error at or near "=" LINE 1: ...er_status_id = order_status WHERE 1183089600 < = created ... ^ in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 126.
    * user warning: query: SELECT COUNT(*) as count, title FROM uc_orders LEFT JOIN uc_order_statuses ON order_status_id = order_status WHERE 1183089600 < = created AND created <= 1185681599 AND order_status IN ('cancelled', 'in_checkout', 'pending', 'paypal_pending', 'processing', 'completed') GROUP BY uc_order_statuses.title ORDER BY weight ASC in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 145.
    * warning: pg_query() [function.pg-query]: Query failed: ERROR: syntax error at or near "=" LINE 1: ...er_status_id = order_status WHERE 1185681600 < = created ... ^ in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 126.
    * user warning: query: SELECT COUNT(*) as count, title FROM uc_orders LEFT JOIN uc_order_statuses ON order_status_id = order_status WHERE 1185681600 < = created AND created <= 1188359999 AND order_status IN ('cancelled', 'in_checkout', 'pending', 'paypal_pending', 'processing', 'completed') GROUP BY uc_order_statuses.title ORDER BY weight ASC in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 145.
    * warning: pg_query() [function.pg-query]: Query failed: ERROR: syntax error at or near "=" LINE 1: ...er_status_id = order_status WHERE 1188360000 < = created ... ^ in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 126.
    * user warning: query: SELECT COUNT(*) as count, title FROM uc_orders LEFT JOIN uc_order_statuses ON order_status_id = order_status WHERE 1188360000 < = created AND created <= 1191038399 AND order_status IN ('cancelled', 'in_checkout', 'pending', 'paypal_pending', 'processing', 'completed') GROUP BY uc_order_statuses.title ORDER BY weight ASC in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 145.
    * warning: pg_query() [function.pg-query]: Query failed: ERROR: syntax error at or near "=" LINE 1: ...er_status_id = order_status WHERE 1191038400 < = created ... ^ in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 126.
    * user warning: query: SELECT COUNT(*) as count, title FROM uc_orders LEFT JOIN uc_order_statuses ON order_status_id = order_status WHERE 1191038400 < = created AND created <= 1193630399 AND order_status IN ('cancelled', 'in_checkout', 'pending', 'paypal_pending', 'processing', 'completed') GROUP BY uc_order_statuses.title ORDER BY weight ASC in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 145.
    * warning: pg_query() [function.pg-query]: Query failed: ERROR: syntax error at or near "=" LINE 1: ...er_status_id = order_status WHERE 1193630400 < = created ... ^ in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 126.
    * user warning: query: SELECT COUNT(*) as count, title FROM uc_orders LEFT JOIN uc_order_statuses ON order_status_id = order_status WHERE 1193630400 < = created AND created <= 1196308799 AND order_status IN ('cancelled', 'in_checkout', 'pending', 'paypal_pending', 'processing', 'completed') GROUP BY uc_order_statuses.title ORDER BY weight ASC in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 145.
    * warning: pg_query() [function.pg-query]: Query failed: ERROR: syntax error at or near "=" LINE 1: ...er_status_id = order_status WHERE 1196308800 < = created ... ^ in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 126.
    * user warning: query: SELECT COUNT(*) as count, title FROM uc_orders LEFT JOIN uc_order_statuses ON order_status_id = order_status WHERE 1196308800 < = created AND created <= 1198900799 AND order_status IN ('cancelled', 'in_checkout', 'pending', 'paypal_pending', 'processing', 'completed') GROUP BY uc_order_statuses.title ORDER BY weight ASC in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 145.
    * warning: pg_query() [function.pg-query]: Query failed: ERROR: syntax error at or near "=" LINE 1: ...er_status_id = order_status WHERE 1198900800 < = created ... ^ in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 126.
    * user warning: query: SELECT COUNT(*) as count, title FROM uc_orders LEFT JOIN uc_order_statuses ON order_status_id = order_status WHERE 1198900800 < = created AND created <= 1201579199 AND order_status IN ('cancelled', 'in_checkout', 'pending', 'paypal_pending', 'processing', 'completed') GROUP BY uc_order_statuses.title ORDER BY weight ASC in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 145.
    * warning: pg_query() [function.pg-query]: Query failed: ERROR: syntax error at or near "=" LINE 1: ...er_status_id = order_status WHERE 1201579200 < = created ... ^ in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 126.
    * user warning: query: SELECT COUNT(*) as count, title FROM uc_orders LEFT JOIN uc_order_statuses ON order_status_id = order_status WHERE 1201579200 < = created AND created <= 1204257599 AND order_status IN ('cancelled', 'in_checkout', 'pending', 'paypal_pending', 'processing', 'completed') GROUP BY uc_order_statuses.title ORDER BY weight ASC in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 145.
    * warning: pg_query() [function.pg-query]: Query failed: ERROR: syntax error at or near "=" LINE 1: ...er_status_id = order_status WHERE 1204257600 < = created ... ^ in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 126.
    * user warning: query: SELECT COUNT(*) as count, title FROM uc_orders LEFT JOIN uc_order_statuses ON order_status_id = order_status WHERE 1204257600 < = created AND created <= 1204343999 AND order_status IN ('cancelled', 'in_checkout', 'pending', 'paypal_pending', 'processing', 'completed') GROUP BY uc_order_statuses.title ORDER BY weight ASC in /usr/local/apache2/htdocs/includes/database.pgsql.inc on line 145.

I also observed that the Custom Sales Summary report shows 19 total orders but 0 orders for each individual week. See the attached screen shot to see what I'm talking about,

rszrama’s picture

Something is jacked on your end that we can't fix. Nowhere in the code is <= separated out into < =. I'd hold your webhost suspect or something and make sure you're running a good version of Postgres.

WISEOZ’s picture

Status: Active » Fixed

Fixed!

Oddly enough, we found "< =" on line 580 of the version we had (which was from 3/22 bazaar). We pulled the 3/24 version from bazaar and it's now correct.

Anonymous’s picture

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for two weeks with no activity.