if exist postgres code example Example: postgresql select exist select exists(select 1 from contact where id=12)