When you fire up rails dbconsole
you can easily execute commands such as:
select * from users limit 1;
However some commands require using Postgres functions such as now()
or timezone(zone, timestamp)
How can you evaluate Postgres functions without needing to select data?
It would be nice to be able to play with some of these functions without having to wrap them into a select statement.
=> now()
# now | 2013-11-18 22:32:48.814876+00
How can I do this directly from dbconsole
?