-
Notifications
You must be signed in to change notification settings - Fork 7
Useful Code snippets
Jeremy Goldstein edited this page May 4, 2017
·
31 revisions
Code examples useful for query construction
round(cast (fund.appropriation-fund.expenditure as numeric (12,2))/100, 2) AS "CASH BALANCE"
date(order_date_gmt)
date_part('year', order_date_gmt)
CASE
WHEN SUBSTRING(i.location_code,4,1)='j' THEN 'Juv'
WHEN SUBSTRING(i.location_code,4,1)='y' THEN 'YA'
Else 'Adult'
END AS "Age level"