Monday 15 September 2014

sql - add value to a subquery mysql -


I have this simple query:

  Select images from the selected images. `Picture`` user_id` IN (SELECT below_ID FAR` `as follows`` FOLLER_ID = 5717 and` AS'` accepted '= 1) ID DESC limit 1 99 OFFSET 0   

I want to add a price for everything subquery has been returned. So if subquarious returns

  23 59 14 77   

I should have:

  23 59 14 77 86 Code>  

Attach 86 times all the time ..

If you were always 86 If you want to add, then use union all on subcarrier, it will ensure that 86 is always included in these sections:

  Choose between the differences. `Bistem` In 'User You' (Select In is the following ADAd 'Assails', where `` Foller_ID` = 5717 & `` Approved` = 1 Union as selected 86) 1000 Office from the limit of ID DESC 0  < / Pre>  

No comments:

Post a Comment