Learn how to fetch records from the database. Also learn how to convert the database records into JSON and send them back to the user.
- [Instructor] Before starting to implement…the get all dishes function,…we need to do a couple of things with our Postgres database.…Open up Postico and go to nadiasgarden.…Inside the dishes.…You will notice that, by default,…the application, Postico, opens up your table…in the Content view.…We need the Structure view so we can add edit…the name of the columns.…
Go ahead and select the Structure tab.…And you will notice that now the Postico app…switches from the Content view to the Structure view.…And go ahead and change the name of the column…from imageURL camel case to imageurl all small case.…Postgres database doesn't really like…if you use camel casing or upper letters.…This will make our life much easier…when working with a Postgres database.…
Once you have done that, go ahead and also change the port…from 8080 to 8090, because 8080 port is a common port,…which can be used by Postgres database.…Once you have made those changes,…let's go ahead and create a connection to our database.…We will start by adding an instance called connection,…
Released
1/5/2018- Reviewing the concepts behind server-side Swift programming
- Different server-side Swift frameworks
- Setting up a Kitura project
- Adding HeliumLogger for debugging
- Accessing JSON passed parameters using Kitura.
- Reading URL parameters and URL encoded form parameters
- Configuring the PostgreSQL database
- Fetching, inserting, and deleting records from the database
- Integrating a Kitura API with an iPhone app
Share this video
Embed this video
Video: Fetching records from the database