13. SQL and Databases

Overview

This chapter's aim is to enable you to connect to SQL databases with the help of the Go programming language.

You will start by learning to connect to databases, creating tables in a database and insert data into and retrieve data from tables. By the end of this chapter, you will be able to update and delete data in specific tables, and also truncate and drop tables.

Introduction

In the previous chapter, you learned how to interact with the system your Go app is running on. You learned the importance of exit codes and how to customize your scripts to take arguments, thus adding flexibility to your applications. You also learned the mastery of handling different signals that your application receives.

In this ...

Get The Go Workshop now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.