SELECT 1 + ('1' || '2')::integer
postgres=# postgres=# postgres=# SELECT 1 + ('1' || '2')::integer AS add_one_to_twelve; add_one_to_twelve ------------------- 13 (1 row) postgres=#