Skip site navigation (1) Skip section navigation (2)

Peripheral Links

Header And Logo

PostgreSQL
| The world's most advanced open source database.

Site Navigation

Search archives
  Advanced Search

Re: print/return only the first X chars of a varchar column?


  • From: Adrian Klaver <aklaver(at)comcast(dot)net>
  • To: pgsql-general(at)postgresql(dot)org
  • Cc: Kevin Kempter <kevink(at)consistentstate(dot)com>
  • Subject: Re: print/return only the first X chars of a varchar column?
  • Date: Mon, 31 Aug 2009 07:53:08 -0700
  • Message-id: <200908310753.09061.aklaver@comcast.net> <text/plain>

On Monday 31 August 2009 7:49:12 am Kevin Kempter wrote:
> Hi all;
>
> I'm selecting from a table that has a varchar(1000) but I only want to
> display the firs 20 characters.  Looked at the string functions in the docs
> but nothing jumped out...
>
> Suggestions?
>
>
> Thanks in advance

substring(string [from int] [for int])	


-- 
Adrian Klaver
aklaver(at)comcast(dot)net



Home | Main Index | Thread Index

Privacy Policy | About PostgreSQL
Copyright © 1996 – 2012 PostgreSQL Global Development Group