Ignore:
Timestamp:
2009/06/22 19:40:22 (15 years ago)
Author:
Seasoft
Message:

MySQL の vw_products_nonclass のロジックを PostgreSQL のもので置換する。

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/comu-ver2/data/class/db/dbfactory/SC_DB_DBFactory_MYSQL.php

    r18063 r18135  
    360360 
    361361            "vw_products_nonclass" => ' 
    362                 (SELECT 
    363                     T1.product_id, 
    364                     T1.name, 
    365                     T1.deliv_fee, 
    366                     T1.sale_limit, 
    367                     T1.sale_unlimited, 
    368                     T1.category_id, 
    369                     T1.rank, 
    370                     T1.status, 
    371                     T1.product_flag, 
    372                     T1.point_rate, 
    373                     T1.comment1, 
    374                     T1.comment2, 
    375                     T1.comment3, 
    376                     T1.comment4, 
    377                     T1.comment5, 
    378                     T1.comment6, 
    379                     T1.file1, 
    380                     T1.file2, 
    381                     T1.file3, 
    382                     T1.file4, 
    383                     T1.file5, 
    384                     T1.file6, 
    385                     T1.main_list_comment, 
    386                     T1.main_list_image, 
    387                     T1.main_comment, 
    388                     T1.main_image, 
    389                     T1.main_large_image, 
    390                     T1.sub_title1, 
    391                     T1.sub_comment1, 
    392                     T1.sub_image1, 
    393                     T1.sub_large_image1, 
    394                     T1.sub_title2, 
    395                     T1.sub_comment2, 
    396                     T1.sub_image2, 
    397                     T1.sub_large_image2, 
    398                     T1.sub_title3, 
    399                     T1.sub_comment3, 
    400                     T1.sub_image3, 
    401                     T1.sub_large_image3, 
    402                     T1.sub_title4, 
    403                     T1.sub_comment4, 
    404                     T1.sub_image4, 
    405                     T1.sub_large_image4, 
    406                     T1.sub_title5, 
    407                     T1.sub_comment5, 
    408                     T1.sub_image5, 
    409                     T1.sub_large_image5, 
    410                     T1.sub_title6, 
    411                     T1.sub_comment6, 
    412                     T1.sub_image6, 
    413                     T1.sub_large_image6, 
    414                     T1.del_flg, 
    415                     T1.creator_id, 
    416                     T1.create_date, 
    417                     T1.update_date, 
    418                     T1.note, 
    419                     T1.deliv_date_id, 
    420                     T2.product_id_sub, 
    421                     T2.product_code, 
    422                     T2.price01, 
    423                     T2.price02, 
    424                     T2.stock, 
    425                     T2.stock_unlimited, 
    426                     T2.classcategory_id1, 
    427                     T2.classcategory_id2 
    428                 FROM (SELECT * FROM dtb_products &&noncls_where&&) AS T1 LEFT JOIN 
    429                 (SELECT 
    430                 product_id AS product_id_sub, 
    431                 product_code, 
    432                 price01, 
    433                 price02, 
    434                 stock, 
    435                 stock_unlimited, 
    436                 classcategory_id1, 
    437                 classcategory_id2 
    438                 FROM dtb_products_class WHERE classcategory_id1 = 0 AND classcategory_id2 = 0) 
    439                 AS T2 
    440                 ON T1.product_id = T2.product_id_sub) ', 
     362                ( 
     363                    SELECT * 
     364                    FROM 
     365                        dtb_products AS T1 
     366                        LEFT JOIN 
     367                        ( 
     368                            SELECT 
     369                                product_id AS product_id_sub, 
     370                                product_code, 
     371                                price01, 
     372                                price02, 
     373                                stock, 
     374                                stock_unlimited, 
     375                                classcategory_id1, 
     376                                classcategory_id2 
     377                            FROM dtb_products_class 
     378                            WHERE 
     379                                classcategory_id1 = 0 
     380                                AND classcategory_id2 = 0 
     381                        ) AS T2 
     382                        ON T1.product_id = T2.product_id_sub 
     383                ) 
     384            ', 
    441385 
    442386            "vw_products_allclass" => " 
Note: See TracChangeset for help on using the changeset viewer.