Postgres Use Variable In Soql Substring In Postgresql