February 2020
Intermediate to advanced
404 pages
8h 42m
English
GORM provides methods for all operations that can be done in the database/sql package. We can install GORM using the dep tool. In this section, we will look at with examples of how to insert, retrieve, and query PostgreSQL JSON using the GORM package.
For the full documentation about this ORM, visit http://jinzhu.me/gorm/. Let's write a program that implements the Shipment and Package types as JSON models. We'll use the same models that we defined in the previous chapter for logistics. Let's look at the steps:
mkdir jsonstoremkdir jsonstore/helpertouch jsonstore/helper/models.go
Read now
Unlock full access