O'Reilly logo

Learning Sinatra by Manoj Sehrawat, Sudeep Agarwal

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Using SQL on Heroku

We already set up SQL for our local machine and we have to perform a similar activity for the Heroku app. However, we cannot install or uninstall this directly on Heroku, so instead, we will add add-ons for this. Everything on Heroku is available as an add-on as this is their model for their platform services (such as databases). Whenever you need an additional service, you need to enable its add-on. So, let's add the add-on for SQL, but for a free account, Heroku only provides the PostgreSQL database! Not a problem; let's use it for production. This is the power of using Object-relational mapping (ORM), we just change the adapter and its settings and we are ready to use the new database. To enable the SQL add-on, we need to ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required