O'Reilly logo

Greenplum - Architecture and SQL by Leona Coffing, Tom Coffing

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 18 – Character Strings

“It’s always been and always will be the same in the world: the horse does the work and the coachman is tipped.”

- Anonymous

The LENGTH Command Counts Characters

image

The LENTH command counts the number of characters. If 'Tom' was in the Employee_Table, his length would be three.

The LENGTH Command – Spaces can Count too

image

If ‘T o m’ was in the Employee_Table, his length would be 5. Yes, spaces in between do count as characters.

The LENGTH Command Doesn't Count Trailing Spaces

Last_Name  

 Lnth

Chambers

  8

Coffing ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required