May 19, 2020 By Andreas Christian 2 min read

There are many important factors when choosing a database, and different roles within the organization may have different priorities.

Among the different perspectives, the CFO might be interested in commercial considerations (e.g., license, support, hardware footprint), the CEO might be interested in stability and performance, and developers like to use databases that enable them to build faster and better.

If you are looking for new, innovative tools to develop backend database applications, read on. IBM has published a Go language driver on GitHub that facilitates rapid database application development with Db2.

Why use Go?

Many well-known applications and tools are implemented in Go language; for example, Docker, Kubernetes, and Terraform are all written in Go. Even Red Hat OpenShift, IBM’s choice of container platform, is written in Go.

The Go programming language was designed at Google in 2007. The goal was to improve programming productivity and to address some of the problems of C/C++. Some important Go features include automatic garbage collection (to avoid memory leaks) and memory safety (pointers cannot be modified).

The good news for all C/C++ programmers is that, syntactically, Go is very similar to C but uses a more simplified syntax. And, the good news for all the Python fans out there is that Go provides a build-in map type which is similar to the dictionary type in Python. There is also a Go interpreter available that facilitates rapid prototyping. A key differentiator from Python, however, is that Go uses static typing, which helps to detect errors early on in the development cycles. In addition, Go is orders of magnitude faster than Python.

So far, we talked about developer needs. The next section is more for the CEO and CFO.

Why use Db2?

When Db2 compression was invented, it significantly reduced the storage footprint while retaining performance. SAP customers, especially, migrated to Db2 to benefit from storage and memory savings. Another milestone was Db2 pureScale, which added horizontal scale-out options for OLTP workloads. Later on, Db2 BLU (a columnar database engine) was added to accelerate analytic workloads. Many customers started to sunset their in-memory analytic accelerators and adopted Db2 BLU.

What is the latest Db2 move? It is the move to the cloud! Db2 now runs containerized on OpenShift. Since OpenShift is supported by all major cloud providers, customers can easily move their Db2 databases across clouds.

Get started with Db2 and Go

In summary, Go language and Db2 are a great match. They enable developers to rapidly build database applications and help to reduce programming errors. The speed of compiled Go programs and Db2 enables customers to build fast and modern transactional and analytic applications in the cloud.

If you’d like to begin working with Go and Db2, take the free Go-Db2 programming lab in the IBM cloud. The lab environment has everything pre-installed: Go, Db2, the Db2-Go driver, and Jupyter notebooks with lab instructions that allow you to interactively try out Go code examples. You also find advanced Db2-Go code that shows for example how to work with Db2 cursors and Db2 parameter markers.

For other database labs, visit IBM Demos and select the Hybrid Data Management segment

More from Cloud

Hybrid cloud examples, applications and use cases

7 min read - To keep pace with the dynamic environment of digitally-driven business, organizations continue to embrace hybrid cloud, which combines and unifies public cloud, private cloud and on-premises infrastructure, while providing orchestration, management and application portability across all three. According to the IBM Transformation Index: State of Cloud, a 2022 survey commissioned by IBM and conducted by an independent research firm, more than 77% of business and IT professionals say they have adopted a hybrid cloud approach. By creating an agile, flexible and…

Tokens and login sessions in IBM Cloud

9 min read - IBM Cloud authentication and authorization relies on the industry-standard protocol OAuth 2.0. You can read more about OAuth 2.0 in RFC 6749—The OAuth 2.0 Authorization Framework. Like most adopters of OAuth 2.0, IBM has also extended some of OAuth 2.0 functionality to meet the requirements of IBM Cloud and its customers. Access and refresh tokens As specified in RFC 6749, applications are getting an access token to represent the identity that has been authenticated and its permissions. Additionally, in IBM…

How to move from IBM Cloud Functions to IBM Code Engine

5 min read - When migrating off IBM Cloud Functions, IBM Cloud Code Engine is one of the possible deployment targets. Code Engine offers apps, jobs and (recently function) that you can (or need) to pick from. In this post, we provide some discussion points and share tips and tricks on how to work with Code Engine functions. IBM Cloud Code Engine is a fully managed, serverless platform to (not only) run your containerized workloads. It has evolved a lot since March 2021, when…

Sensors, signals and synergy: Enhancing Downer’s data exploration with IBM

3 min read - In the realm of urban transportation, precision is pivotal. Downer, a leading provider of integrated services in Australia and New Zealand, considers itself a guardian of the elaborate transportation matrix, and it continually seeks to enhance its operational efficiency. With over 200 trains and a multitude of sensors, Downer has accumulated a vast amount of data. While Downer regularly uncovers actionable insights from their data, their partnership with IBM® Client Engineering aimed to explore the additional potential of this vast dataset,…

IBM Newsletters

Get our newsletters and topic updates that deliver the latest thought leadership and insights on emerging trends.
Subscribe now More newsletters