Someone in a PostgreSQL chat room gave me this syntax. It is used in a VIEW that outputs an RSS feed link:
to_char(tips_chronic_pain_weekly_selection.start_date, 'YYYY/MM/DD'::text) Example output: 2021/09/13 I am not familiar with how this works. Am I able to remove the leading 0 in both month and day? This was given to me several months ago as a shorten version of:
concat( extract( YEAR FROM tips_physical_disability_weekly_selection.start_date), '/', extract( MONTH FROM tips_physical_disability_weekly_selection.start_date), '/', extract( DAY FROM tips_physical_disability_weekly_selection.start_date) )