SELECT 1 + ('1' || '2')::integer : Cast « Data Type « PostgreSQL






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=#

           
       








Related examples in the same category

1.round(4.0, 4)
2.round(CAST (4 AS numeric), 4)
3.Cast char as integer