When I talk to various people about PostgreSQL, based on where they are in the process of analyzing it, I get asked many similar questions. One of the most frequently asked questions is: What is the PostgreSQL licensing model? Here is my attempt to address this question from the perspective of what the PostgreSQL license means for your business.
Go Ahead, Read It - It’s Really Not That Scary
Let’s be honest with ourselves, we are really not in the habit of reading license agreements - they are best left to the legal department to decipher. And seriously, licenses have become so complex and so detailed that even if I try really really hard to read just a few clauses, my head starts to hurt.
The PostgreSQL License is different though.
I have reproduced the license in full at (more…)
The PostgreSQL user community is becoming spoilt with a choice of excellent events organized by both local user groups and commercial organizations supporting the PostgreSQL project. And amongst the events taking place in December, the one you definitely shouldn't miss attending is CHAR(16).
‘CHAR(16): Scalability for Business’ is intended to fulfill a different requirement - different to the many excellent PostgreSQL related events we attend and support. Different because we’ve set out to organize a conference that is business focused and specifically we want to highlight the impact the PostgreSQL Development Group is making on database scalability for enterprises, addressing the need to scale.
The need to scale databases is probably high on most technical departments (more…)
PGDG announced the General Availability of PostgreSQL 9.6 on the 29th of September. Like each year, this new release brings with it a lot of exciting new features. Using these features, of course, requires installing PostgreSQL ... a task that can be a touch daunting for novice users. 2UDA, a graphical installer for PostgreSQL, is designed to make the installation as easy as 1-2-3.
Admittedly, the primary purpose of 2UDA is to provide a unified package for data analytics using PostgreSQL. But it can just as easily be used to install PostgreSQL on the most popular platforms - Windows, OSX, & Linux. This is especially helpful for Windows & OSX, where users are more accustomed to graphical point-and-click installers.
PostgreSQL 9.6 is now available in 2UDA installers and (more…)
The latest version of PostgreSQL 9.6 is planned to be released later today, bringing with it some much anticipated features and updates. As the most advanced open source database, PostgreSQL strives to release a major version roughly once every year. With an active and collaborative community, this PostgreSQL release boasts impressive features and updates thanks to contributions from many of the highly knowledgeable community members.
The expanding team at 2ndQuadrant has continued to show dedication to the PostgreSQL database project by contributing heavily to the PostgreSQL 9.6 release. Parallel execution of large queries has been a known shortcoming of PostgreSQL for some time, but this is no longer an issue with the 9.6 release. David Rowley and Simon Riggs contributed to (more…)
I was in Jakarta a couple of weeks ago and there happened to be a meetup of the Indonesia PUG in Bandung while I was there. Because it is just a 2 hour, rather picturesque drive, from Jakarta, I thought it was too good of an opportunity to miss. So I showed up.
The meetup was hosted by Julyanto Sutandang of Equnix Business Solutions and the conversation was mostly centered around convincing the local technology industry about PostgreSQL in comparison to Oracle. We got into fairly detailed discussions on the typical challenges of moving an Oracle production database to PostgreSQL. I especially love talking about hierarchical queries - Oracle's CONNECT BY PRIOR and PostgreSQL's WITH RECURSIVE.
It was very interesting to find out how popular BDR - the Multi Master (more…)
Querydsl is a domain model centric ORM that was created out of a need to add typesafety to HQL. As demonstrated in my blog on HQL, to write queries using HQL, at times long string concatenations need to be used. Such strings are not only hard to read, they are prone to runtime errors, avoiding which is the main driver for using ORMs.
Although it was initially primarily targeted at HQL, Querydsl is now also available for JPA, JDO, JDBC, Lucene, Hibernate Search, MongoDB, Collections and RDFBean.
Why Use Querydsl?
The biggest advantage Querydsl offers is typesafety. Rather than relying on strings, it provides you the ability of querying your database using functions. This takes care of syntactic correctness and ensures that you don’t get runtime errors.
With typesafety, comes the (more…)
jOOQ is an ORM-alternative that is relational model centric rather than domain model centric like most ORMs. For example, while Hibernate lets you write Java code and then automatically translates it to SQL, jOOQ let’s you write relational objects in your database using SQL and then automatically generates Java code to map to those relational objects.
The writers of jOOQ believe in the power of SQL and assume that you want low level control of the SQL running for your application. This means that you can write your database and your schema without having to worry about how (and if!) it can be handled in Java.
Why Use jOOQ?
While JPA provides a huge framework with a great deal of flexibility and power, it can very quickly become quite complex. jOOQ provides a simpler interface for (more…)
In my previous blog, I talked about using Java arrays to talk to PostgreSQL arrays. This blog is going to go one step further in using Java against the database. Hibernate is an ORM implementation available to use with PostgreSQL. Here we discuss its query language, HQL.
The syntax for HQL is very close to that of SQL, so anyone who knows SQL should be able to ramp up very quickly. The major difference is that rather than addressing tables and columns, HQL deals in objects and their properties. Essentially, it is a complete object oriented language to query your database using Java objects and their properties. As opposed to SQL, HQL understands inheritance, polymorphism, & association. Code written in HQL is translated by Hibernate to SQL at runtime and executed against the (more…)
Arrays are a powerful programming feature frequently used by developers, both in Java and in PL/pgSQL. Interfaces can potentially become tricky, however, when the two try and talk to each other. This section explores how you can write simple code that uses the java.sql.Array Interface to insert, retrieve, & update arrays in PostgreSQL.
To illustrate the functionality, let’s set up a simple table that stores country names in one column as TEXT and a list of some of the country’s cities in the second column as a TEXT ARRAY.
CREATE TABLE city_example (
Now we will use the JDBC interface to insert data into this table, retrieve it, and update it.
Anyone familiar with Java has used arrays in one form or the other. Before these (more…)
It is always exciting to meet community members and exchange ideas about PostgreSQL and the eco-system around the database. I was lucky enough to be a part of FOSDEM PGDay in Brussels on 29th January this year. 3 of 2ndQuadrant's very best spoke at the event. If you missed the talks, you can take a look at their slide decks shared below.
Craig's talk on 'Logical Replication with pglogical'
Gulcin's talk on 'Managing PostgreSQL with Ansible'
Tomas' talk on 'PostgreSQL Performance on EXT4, XFS, F2FS, BTRFS, & ZFS'
I will be sure to direct any queries you might have to the experts themselves (more…)