Ticket #1013 (closed バグ指摘: 修正済)

Opened 10 years ago

Last modified 10 years ago

[管理画面]売上集計:職業別集計が出ない不具合、postgreSQLでDBエラー

Reported by: kotani Owned by: shutta
Priority: Milestone: EC-CUBE2.11.0 リファクタリングProject
Component: 管理画面 Version: 2.11.0 β
Keywords: Cc:
修正済み:

Description

関連チケット:#962

1.職業別集計で、データはあるのに集計結果が表示されない。(MySQL,PostgreSQL)

2.postgreSQLで、下記DBエラーが発生している。
・商品別集計
・年代別集計
・会員別集計

▼▼▼ デバッグ情報ここから ▼▼▼

http://192.168.56.103/eccube211/admin/total/??

SERVER_ADDR: 192.168.56.103
REMOTE_ADDR: 192.168.56.1
USER_AGENT: Mozilla/5.0 (Windows; U; Windows NT 6.1; ja; rv:1.9.2.13) Gecko/20101203 Firefox/3.6.13

/mnt/working_copy/eccube211/html/admin/total/index.php 34:LC_Page_Admin_Total_Ex->process
/mnt/working_copy/eccube211/data/class_extends/page_extends/admin/total/LC_Page_Admin_Total_Ex.php 56:LC_Page_Admin_Total->process
/mnt/working_copy/eccube211/data/class/pages/admin/total/LC_Page_Admin_Total.php 96:LC_Page_Admin_Total->action
/mnt/working_copy/eccube211/data/class/pages/admin/total/LC_Page_Admin_Total.php 144:call_user_func_array
 :LC_Page_Admin_Total->lfGetOrderProducts
/mnt/working_copy/eccube211/data/class/pages/admin/total/LC_Page_Admin_Total.php 549:SC_Query->select
/mnt/working_copy/eccube211/data/class/SC_Query.php 153:SC_Query->getAll
/mnt/working_copy/eccube211/data/class/SC_Query.php 265:SC_Query->prepare
/mnt/working_copy/eccube211/data/class/SC_Query.php 870:trigger_error
▼▼▼ エラーメッセージ ▼▼▼
https://192.168.56.103/eccube211/admin/total/?

SERVER_ADDR: 192.168.56.103
REMOTE_ADDR: 192.168.56.1
USER_AGENT: Mozilla/5.0 (Windows; U; Windows NT 6.1; ja; rv:1.9.2.13) Gecko/20101203 Firefox/3.6.13

SQL: SELECT 
                product_id,
                product_code,
                product_name,
                SUM(quantity) AS products_count,
                COUNT(order_id) AS order_count,
                price,
                (price * SUM(quantity)) AS total FROM dtb_order_detail JOIN dtb_order USING(order_id) WHERE  create_date >= '2011/2/1 00:00:00' AND  create_date < date('2011/03/01') AND dtb_order.del_flg = 0 AND dtb_order.status <> 3 GROUP BY product_id ORDER BY total DESC 

MDB2 Error: unknown error

prepare: [Error message: Unable to create prepared statement handle]
[Last executed query: EXECUTE mdb2_statement_pgsql_1f125aee1a0e0ab9067070c8478b27e69126915ff ('cqjf3vfrp93lblsc6vqmrlpk07')]
[Native message: ERROR:  column "dtb_order_detail.product_code" must appear in the GROUP BY clause or be used in an aggregate function]


/mnt/working_copy/eccube211/html/admin/total/index.php 34:LC_Page_Admin_Total_Ex->process
/mnt/working_copy/eccube211/data/class_extends/page_extends/admin/total/LC_Page_Admin_Total_Ex.php 56:LC_Page_Admin_Total->process
/mnt/working_copy/eccube211/data/class/pages/admin/total/LC_Page_Admin_Total.php 96:LC_Page_Admin_Total->action
/mnt/working_copy/eccube211/data/class/pages/admin/total/LC_Page_Admin_Total.php 144:call_user_func_array
 :LC_Page_Admin_Total->lfGetOrderProducts
/mnt/working_copy/eccube211/data/class/pages/admin/total/LC_Page_Admin_Total.php 549:SC_Query->select
/mnt/working_copy/eccube211/data/class/SC_Query.php 153:SC_Query->getAll
/mnt/working_copy/eccube211/data/class/SC_Query.php 265:SC_Query->prepare
/mnt/working_copy/eccube211/data/class/SC_Query.php 867:MDB2_Driver_pgsql->prepare
/mnt/working_copy/eccube211/data/module/MDB2/Driver/pgsql.php 967:MDB2_Driver_Common->raiseError
/mnt/working_copy/eccube211/data/module/MDB2.php 1497:PEAR->raiseError
/mnt/working_copy/eccube211/data/module/PEAR.php 557:MDB2_Error->MDB2_Error
/mnt/working_copy/eccube211/data/module/MDB2.php 1009:PEAR_Error->PEAR_Error
▲▲▲ エラーメッセージ ▲▲▲


▲▲▲ デバッグ情報ここまで ▲▲▲

Change History

comment:1 Changed 10 years ago by shutta

  • Owner changed from somebody to shutta
  • Status changed from new to assigned

comment:2 Changed 10 years ago by shutta

  • Status changed from assigned to closed
  • Resolution set to 修正済

r20238,r20239,r20241,r20242,r20243 にて修正。
ただ、グラフの表示がおかしいので、別途チケットを登録しておきました。(#1021)

Note: See TracTickets for help on using tickets.