ERROR: invalid input syntax for integer: "" LINE 1: SELECT sort FROM photo_albums WHERE alb_id='' ^