Postgresql Select Data From Another Sql Interview Coding