From 0d74277d0e301b082ad1dc4ed15750d9ea1c8bdf Mon Sep 17 00:00:00 2001 From: Jimmy99 Date: Wed, 6 Apr 2016 08:10:47 +0200 Subject: [PATCH] Update 05.4.md typographical errors and improved readability --- en/05.4.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/en/05.4.md b/en/05.4.md index c1e58ce6..76bda2cf 100644 --- a/en/05.4.md +++ b/en/05.4.md @@ -1,6 +1,6 @@ # 5.4 PostgreSQL -PostgreSQL is an object-relational database management system available for many platforms including Linux, FreeBSD, Solaris, Microsoft Windows and Mac OS X. It is released under an MIT-style license, and is thus free and open source software. It's larger than MySQL because it's designed for enterprise usage like Oracle. Postgresql is good choice for enterprise type projects. +PostgreSQL is an object-relational database management system available for many platforms including Linux, FreeBSD, Solaris, Microsoft Windows and Mac OS X. It is released under an MIT-style license, and is thus free and open source software. It's larger than MySQL because it's designed for enterprise usage as an alternative to Oracle. Postgresql is a good choice for enterprise type projects. ## PostgreSQL drivers @@ -10,7 +10,7 @@ There are many database drivers available for PostgreSQL. Here are three example - [https://github.com/jbarham/gopgsqldriver](https://github.com/jbarham/gopgsqldriver) supports `database/sql`, written in pure Go. - [https://github.com/lxn/go-pgsql](https://github.com/lxn/go-pgsql) supports `database/sql`, written in pure Go. -I'll use the first one in my following examples. +I will use the first one in the examples that follow. ## Samples @@ -104,7 +104,7 @@ An example: } Note that PostgreSQL uses the `$1, $2` format instead of the `?` that MySQL uses, and it has a different DSN format in `sql.Open`. -Another thing is that the Postgres driver does not support `sql.Result.LastInsertId()`. +Another thing is that the PostgreSQL driver does not support `sql.Result.LastInsertId()`. So instead of this, stmt, err := db.Prepare("INSERT INTO userinfo(username,departname,created) VALUES($1,$2,$3);")