How to format date?
I tried:
but it does not return an array of objects. How do I get an array of objects from the above query?
Similar to what this statement returns:
7 Replies
You might need to cast
created_at
as a timestamp.
Or use to_date insteadPostgreSQL Documentation
9.8. Data Type Formatting Functions
9.8. Data Type Formatting Functions # The PostgreSQL formatting functions provide a powerful set of tools for converting various data types …
yea but the query still doesn't return an array of objects. It returns this:
I'm sorry, copying from my editor tooltip isn't working rn
whereas, a normal query returns simply an array of objects, which is easy to consume.
You need to await the query. It is async
oh silly me
It works!!
thanks!!!
SOLVED