Netezza Performance Server

 View Only

Announcing nzgo: Go language database driver for Netezza

By Abhishek Jog posted Mon December 21, 2020 07:49 AM

  

nzgo: Golang database driver for Netezza Performance Server

Since the immergence of Golang, it has become widely popular language for programmers to develop applications. IBM has now provided a native Golang database driver to work with Netezza Performance Server (a.k.a NPS).

nzgo provides specific implementation of standard Golang database/sql package to connect with NPS database engine.

Golang database/sql package for working with databases. It offers multiple features such as connection pooling, thread safety, a common set of Go types etc. Database drivers are used along with this package. The nzgo package provides database driver for Netezza and offers additional features including TLSv1.2 crypto support, transaction support, configurable logging, external table support, support for newly added NPS data types including JSON, JSONB and JSONPATH datatypes.

The nzgo driver requires the Go language 1.12 or higher. To start work, simply install nzgo package using go get github.com/IBM/nzgo and connect using below connection parameters:

import "github.com/IBM/nzgo"

connStr := "host=<NPS hostname/IP> user=<username> dbname=<dbname> port=5480 password=<password> sslmode=require sslrootcert=<path to certificate> securityLevel=3"

db, err := sql.Open("nzgo", connStr)

Once connected, you can run any query on the database. You can create objects, fetch, modify, insert, delete any data in the database using your go program.

IBM encourages development community to contribute to this project and also open issues, feature requests. For more information, refer to the nzgo documentation: https://github.com/IBM/nzgo/


#NetezzaPerformanceServer
0 comments
8 views

Permalink