This article is the first part of the Free Full-Stack development in your Browser trilogy, learn how to build a modern PWA using your browser and some unbelievable free tools!
PostgreSQL is a great tool, it offers:
- relational database paradigm (SQL)
- document database paradigm
- stored procedures
- table inheritance and data partitioning
- lot of extensions
- event emitter!!!
In this part of the tutorial you will create an account in ElephantSQL and set up a new database.
Open your browser and go to www.elephantsql.com. Once there you can follow the steps in this video to login with Google or GitHub and create your first free Postgres database:
Later in the tutorial you will need the Postgres Connection String for your app to establish a successful connection with the database.
ElephantSQL provides this information for you as a URL:
Before you dig into back-end code I’d like you to play around with your database and spend some time to get familiar with simple opertions such creating tables, inserting, changind and deleting data.
This is often refferred to as CRUD Operations and it is exactly what you will do in your backend. If you have a direct experience with it is going to be easier.
I’m a MacOS user and the client I suggest you to use is Postico which works fine and it is free of charge for most of its functionalities.
In the next screenshot you can see my connection setup screen:
And once you establish a succesfull connection, you can use the app to perform all the operations that you may think about.
In case you can’t use a Postgres client app, you can navigate to the BROWSER menu and use the console to run SQL queries against your database.
If you are going the “browser” way you need to write plain SQL queries, here is a nice introduction to the subject that will get you up to speed with CRUD operations in SQL for Postgres.
👉 Move to the backend!