select pid as 'id',pnameth 'name',if(now() between pflash_start and pflash_end,pflash_price,pprice) as 'price',pphoto 'photo',pstatus 'status'
,if( (now() between pflash_start and pflash_end) and pprice<pfullprice and pfullprice>0 ,pprice,pfullprice) 'fullprice' from dex_product where pactivate=1 and phide=0 and (porder_end=0 or porder_end>now()) and ( pnameth like '%%https://www.amazon.co.jp/-/en/dp/B0B45BXSSJ/ref=s9_acsd_ri_bw_c2_x_6_i?pf_rd_m=A3P5ROKL5A1OLE&pf_rd_s=merchandised-search-4&pf_rd_r=VB9R0PA3SS450KXC8Z31&pf_rd_t=101&pf_rd_p=a235f63d-0bdb-4bef-84e9-d1fe8e7663d5&pf_rd_i=8432382051%%' or pnameen like '%%https://www.amazon.co.jp/-/en/dp/B0B45BXSSJ/ref=s9_acsd_ri_bw_c2_x_6_i?pf_rd_m=A3P5ROKL5A1OLE&pf_rd_s=merchandised-search-4&pf_rd_r=VB9R0PA3SS450KXC8Z31&pf_rd_t=101&pf_rd_p=a235f63d-0bdb-4bef-84e9-d1fe8e7663d5&pf_rd_i=8432382051%%' or ptag like '%%https://www.amazon.co.jp/-/en/dp/B0B45BXSSJ/ref=s9_acsd_ri_bw_c2_x_6_i?pf_rd_m=A3P5ROKL5A1OLE&pf_rd_s=merchandised-search-4&pf_rd_r=VB9R0PA3SS450KXC8Z31&pf_rd_t=101&pf_rd_p=a235f63d-0bdb-4bef-84e9-d1fe8e7663d5&pf_rd_i=8432382051%%' or pid='https://www.amazon.co.jp/-/en/dp/B0B45BXSSJ/ref=s9_acsd_ri_bw_c2_x_6_i?pf_rd_m=A3P5ROKL5A1OLE&pf_rd_s=merchandised-search-4&pf_rd_r=VB9R0PA3SS450KXC8Z31&pf_rd_t=101&pf_rd_p=a235f63d-0bdb-4bef-84e9-d1fe8e7663d5&pf_rd_i=8432382051' or pbarcode='https://www.amazon.co.jp/-/en/dp/B0B45BXSSJ/ref=s9_acsd_ri_bw_c2_x_6_i?pf_rd_m=A3P5ROKL5A1OLE&pf_rd_s=merchandised-search-4&pf_rd_r=VB9R0PA3SS450KXC8Z31&pf_rd_t=101&pf_rd_p=a235f63d-0bdb-4bef-84e9-d1fe8e7663d5&pf_rd_i=8432382051' ) and pstatus<>'Preorder' order by pid desc limit 0,30