Sooraj S Sooraj S - 8 months ago 53
SQL Question

select sql distinct

I have more than one image with the id 83, 84... I want to select only one image from id 83, 84... using sql `distinct.

Screenshot of data

Answer

Try your query like this

select * from images group by jy_id

or you can try:-

select distinct jy_id, jy_tour_book_picture from images group by jy_id