ここの情報は古いです。ご理解頂いた上でお取り扱いください。

Changeset 10176


Ignore:
Timestamp:
Jan 15, 2009, 4:01:54 PM (11 years ago)
Author:
kiwa
Message:

#3242:PostgreSQL8系だと日時集計にデータを反映させるようにする修正の修正漏れ(2.10)

File:
1 edited

Legend:

Unmodified
Added
Removed
  • OpenPNE/branches/stable-2.10.x/webapp/modules/admin/lib/db_admin.php

    r9725 r10176  
    12841284    if ($month_flag) {
    12851285        if ($GLOBALS['_OPENPNE_DSN_LIST']['main']['dsn']['phptype'] == 'pgsql') {
    1286             $where .= " and substr(r_datetime,1, 7) = ? ";
     1286            $where .= " and substr(r_datetime::text,1, 7) = ? ";
    12871287        } else {
    12881288            $where .= " and left(r_datetime, 7) = ? ";
     
    12911291    } else {
    12921292        if ($GLOBALS['_OPENPNE_DSN_LIST']['main']['dsn']['phptype'] == 'pgsql') {
    1293             $where .= " and substr(r_datetime,1,10) = ? ";
     1293            $where .= " and substr(r_datetime::text,1,10) = ? ";
    12941294        } else {
    12951295            $where .= " and left(r_datetime,10) = ? ";
     
    14631463    if ($month_flag) {
    14641464        if ($GLOBALS['_OPENPNE_DSN_LIST']['main']['dsn']['phptype'] == 'pgsql') {
    1465             $where .= " and substr(r_datetime,1,7) = ? ";
     1465            $where .= " and substr(r_datetime::text,1,7) = ? ";
    14661466        } else {
    14671467            $where .= " and left(r_datetime, 7) = ? ";
     
    14701470    } else {
    14711471        if ($GLOBALS['_OPENPNE_DSN_LIST']['main']['dsn']['phptype'] == 'pgsql') {
    1472             $where .= " and substr(r_datetime,1,10) = ? ";
     1472            $where .= " and substr(r_datetime::text,1,10) = ? ";
    14731473        } else {
    14741474            $where .= " and left(r_datetime,10) = ? ";
     
    15411541    if ($month_flag) {
    15421542        if ($GLOBALS['_OPENPNE_DSN_LIST']['main']['dsn']['phptype'] == 'pgsql') {
    1543             $where .= " and substr(r_datetime,1,7) = ? ";
     1543            $where .= " and substr(r_datetime::text,1,7) = ? ";
    15441544        } else {
    15451545            $where .= " and left(r_datetime, 7) = ? ";
     
    15481548    } else {
    15491549        if ($GLOBALS['_OPENPNE_DSN_LIST']['main']['dsn']['phptype'] == 'pgsql') {
    1550             $where .= " and substr(r_datetime,1,10) = ? ";
     1550            $where .= " and substr(r_datetime::text,1,10) = ? ";
    15511551        } else {
    15521552            $where .= " and left(r_datetime,10) = ? ";
     
    15821582    if ($month_flag) {
    15831583        if ($GLOBALS['_OPENPNE_DSN_LIST']['main']['dsn']['phptype'] == 'pgsql') {
    1584             $where .= " and substr(r_datetime,1,7) = ? ";
     1584            $where .= " and substr(r_datetime::text,1,7) = ? ";
    15851585        } else {
    15861586            $where .= " and left(r_datetime, 7) = ? ";
     
    15891589    } else {
    15901590        if ($GLOBALS['_OPENPNE_DSN_LIST']['main']['dsn']['phptype'] == 'pgsql') {
    1591             $where .= " and substr(r_datetime,1,10) = ? ";
     1591            $where .= " and substr(r_datetime::text,1,10) = ? ";
    15921592        } else {
    15931593            $where .= " and left(r_datetime,10) = ? ";
Note: See TracChangeset for help on using the changeset viewer.