Welcome Guest, Not a member yet? Register   Sign In
How to Print Single Name
#1

(This post was last modified: 07-30-2021, 01:46 AM by InsiteFX. Edit Reason: I fixed it for you next time please use the editor code tags on the menu )

Help me out to fetch only single store Data to below mentioned SQL queries

Code:
select
affiliateURL as url,
`store`.`name`
from
`store`
inner join
`store_coupon_junction` as `scj` on `store`.`id` = `scj`.`storeId` and `scj`.`storeCouponRank` >= 0
inner join
`category_coupon_junction` as `ccj` on `scj`.`couponId` = `ccj`.`couponId` and `ccj`.`categoryCouponRank` >= 0
inner join
`category` on `ccj`.`categoryId` = `category`.`id` and `category`.`active` = 1
inner join
`coupon` on `scj`.`couponId` = `coupon`.`id` and `coupon`.`active` = 1 and `coupon`.`type` != ''
where
`store`.`active` = 1
order by
`store`.`rank` desc
Reply
#2

Please use the [code] tag to format your message so it's readable.
Reply
#3

You will probably need to add a "group by". Something like "group by affiliateURL, store.name".
CodeIgniter 4 tutorials (EN/FR) - https://includebeer.com
/*** NO support in private message - Use the forum! ***/
Reply
#4

did you get any solution ?
Reply
#5

limit 1
Reply




Theme © iAndrew 2016 - Forum software by © MyBB