Database Server Room

Vertica Quick Tip: My SQL History

This blog post was authored by Jim Knicely. In vsql you can use the \s meta-command to view your command line history: If using some other Vertica SQL client, i.e. DbVisualizer, you can also get a history of your current session’s SQL commands like this: Have Fun!

Introducing the Parallel Streaming Transformation Loader (PSTL) Solution

This blog post was authored by Soniya Shah. At Vertica, we understand how important it is that our customers can make decisions in near real time. Being able to do this not only requires the massive parallel processing that Vertica offers, but the ability to transform and ingest your data into Vertica as quickly as...

Vertica Quick Tip: Getting a Word Count

This blog post was authored by Jim Knicely. The Vertica REGEXP_COUNT function returns the number times a regular expression matches a string. You can use it to create your own user-defined SQL function that counts the number of words in a string. dbadmin=> SELECT get_word_count('The Vertica Analytics Platform is purpose built from the very first...

Subscribe For Email Updates

Sign-up and select Vertica in your preferences to receive our monthly Vertica newsletter.

Sign-up

quick sql tips for rows

Vertica Quick Tip: Parsing a String as Rows

This blog post was authored by Jim Knicely. A simple SQL trick makes it easy to expand an entire string into separate rows. i s A w e s o m e ! (19 rows) Now that you’ve expanded the string into rows, you can perform various actions if you encounter certain conditions… i s...

Vertica Quick Tip: Repeating

This blog post was authored by Jim Knicely. The Vertica REPEAT function replicates a string the specified number of times, and concatenates the replicated values as a single string. Examples: dbadmin=> SELECT '1' || repeat('0', 100) AS "One Googolplex"; One Googolplex ------------------------------------------------------------------------------------------------------- 10000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000 (1 row) This function is also very useful if you plan on...

Vertica Quick Tip: Splitting a String into Rows

This blog post was authored by Jim Knicely. The Vertica Text Search feature includes a handy function named StringTokenizerDelim that you can use to split a string into rows by a given delimiter. Have Fun!

Explore Popular Topics

Monitoring Login Failures

This blog post was authored by Curtis Bennett. Security is an ever-present topic on the minds of database administrators. Certainly Vertica has a number of security features like Kerberos, and SSL. This blog isn’t about those! Instead, let’s take a look at a much more simplistic aspect of security which Vertica tracks – login failures....
Commercial passenger plane with Vertica painted on the tail

Blog Post Series: Using Vertica to Track Commercial Aircraft in near Real-Time — Part 5

Part Five: Apache Kafka As discussed in an earlier blog post, we have a continuous stream of messages from aircraft transponders captured and decoded using the DUMP1090 application. We now want to load this data into a series of Vertica tables. As with the streaming nature of the incoming data, with many 10s, possibly 100s...
Three 3D arrows, different colors pointing in different directions

Vertica Quick Tip: Getting Every n-th Row from a Table

This blog post was authored by Jim Knicely. You can use the Vertica MOD function to grab every nth row from a table. Say I want every 2nd row from the table above. I can run the following query to get them: Or for every 3nd row, I’d run this query: Have Fun!

Vertica Quick Tip: What’s the Distance Between Two Points

This blog post was authored by Jim Knicely. Planning a road trip to Disney? How far is it? Vertica has a built-in function called DISTANCE, which returns the distance (in kilometers) between two points. You specify the latitude and longitude of both the starting point and the ending point. You can also specify the radius...
Modern Database Analytics

Vertica Quick Tip: Keeping Track of Data Load File Sources

This blog post was authored by Jim Knicely. If you are like most companies you will be loading data into a Vertica table from many different data files. And if you are like me, you’ll forget later which file a table record arrived in. Fortunately the CURRENT_LOAD_SOURCE function returns the file name used when executing...
Programmer

Operational Considerations for Database Administrators in Eon Mode

This blog post was authored by Shrirang Kamat. The purpose of this document is to familiarize advanced Vertica Enterprise mode users about some of the behavioral similarities and differences between Vertica Enterprise mode and Vertica Eon mode. This document assumes you have a basic understanding about Eon mode architecture. You can find more details about...