select *
from folder f,uploads u
where u.id=f.folderId
and FIND_IN_SET('8', '15,9,13,27')
Please tell to me equivalent to predefind or userdefined postgresql function
You shouldn't be storing comma separated values in the first place, but you can do something like this:
select *
from folder f
join uploads u ON u.id = f.folderId
where '8' = ANY (string_to_array(some_column,','))
string_to_array()
converts a string into a real array based on the passed delimiter