how to write postgres query to ruby on rails code example Example: postgresql rails rails new myApp --database=postgresql