Vertica Blog

Vertica Blog

Quick Tips

Tips in bright neon red letters on a dark background with touchscreens.

Default Custom User Resource Pool

In Vertica versions 12.0.4 and later, you can set a default user resource pool for all users instead of defaulting users to a general pool, using the DefaultResourcePoolForUsers configuration parameter. How to set it? As a dbadmin user, create a user resource pool. The pool name can be used to configure the DefaultResourcePoolForUsers option. In...

Load Balancing on Elastic Kubernetes Clusters

Your long-running sessions could fail after you deployed Vertica on Elastic Kubernetes Cluster (EKS) with Load Balancer as the service type. When the load balancer type is not specified in yaml, by default, EKS generates a classic load balancer with a default connection idle timeout of 60 seconds. The aws-load-balancer-connection-idle-timeout can be set up to...
Helpful Tips in blue text with magnifying glass

Restrict Modifying Table Rows (UPDATE/DELETE) Irrespective of User Privileges

Do you have a table with critical information such as SIEM events or credit card transactions? Do you want to be able to block user access to UPDATE/DELETE rows in those tables? From version 12.0.0, you can do this by setting the tables as IMMUTABLE. This means you can only insert data and not modify...
Tips in bright neon red letters on a dark background with touchscreens.

High Availability for a Vertica in Eon Mode Database with Read-Only Mode

When Vertica is deployed in Eon Mode, there are two major requirements for high availability: maintaining quorum and shard coverage. If either of them is lost, the whole cluster goes down. Before going into details, let us understand what quorum and shard coverage mean. Quorum: In Eon Mode, more than half of the primary nodes...

How to Quickly Install Vertica on Large Clusters

Vertica 12.0.2 introduces a new feature that allows you to install Vertica in parallel on all hosts rather than one at a time as in earlier releases. This reduces the installation time in large clusters. To use this feature, run the --parallel-no-prompts flag with the install_vertica command. This flag can be used only when passwordless...
SQL Query Optimization

Improving COUNT DISTINCT Performance with Approximate Functions

A common analytic use case is to find the number of distinct items in a data set. Vertica performs well at solving COUNT DISTINCT in a few ways. Since Vertica stores all data in columns, it is possible to optimize for COUNT DISTINCT by building a projection that is tuned for this use case. Vertica...

How to run Vertica CE in Windows 10 using Docker

Sometimes we want to test a new version of Vertica. In the past, the best way to do that was to use a Vertica Community Edition (CE) virtual machine. But starting with Vertica version 10.1, there is an easier way to achieve this. There is an official Docker image for the latest Vertica CE version...

Quick Tip: Replacing non-UTF-8 Characters

Vertica database servers expect to receive all data in UTF-8 and Vertica outputs all data in UTF-8. However, you can load or insert data into Vertica that is non UTF-8, but you'll want to clean it up. I used to recommend the REGEXP_REPLACE function for that task, but now there is a better way! Vertica...
Quick Tip - blue button

Quick Tip: MC Adds a New Feedback Button

Do you love Vertica and want to let us know, or want to provide some constructive criticism? Well, now you can easily do that. Starting in Vertica 10.1.x, Management Console added a new Feedback Button which lets you submit a star rating and free-text comments to Vertica. The button displays vertically at the bottom-right of...
Helpful Tips in blue text with magnifying glass

Quick Tip: Determining Database “Cell” Count

The Vertica system tables LICENSE_AUDITS and USER_AUDITS include a mysterious column called CELL_COUNT. What exactly is the Cell Count? It's simply a calculation that looks like this: DATABASE CELL_COUNT = (Table_1 Column Count * Table_1 Row Count) + (Table_2 Column Count * Table_2 Row Count) + … + (Table_n Column Count * Table_n Row Count)...
SQL

Quick Tip: WITH Clause Recursion

Starting with version 10.1.x, Vertica supports recursive queries. These are incredibly useful in modeling and working with self-referential hierarchical data. Let's take a look at a natural instance of this form of data: the manager-subordinate relationship. The following table contains employees (EMP_NAME), their IDs (EMP_ID), and the IDs of their managers (EMP_MGR_ID). For example, the...
Vintage businessman concept wearing futuristic helmet at office

Quick Tip: Combine SQL and vsql Meta-commands on the vsql Command Line

When using vsql, the -c (--command) flag lets you pass a single statement to vsql as a string and then exits. Examples: While you can't combine a SQL statement with a vsql meta-command... ...You can use echo to combine and pipe SQL statements and vsql meta-functions to vsql! Have Fun!