Re: left() in postgres - Mailing list pgsql-general

From Stephan Szabo
Subject Re: left() in postgres
Date
Msg-id 20021025102422.B37463-100000@megazone23.bigpanda.com
Whole thread Raw
In response to Re: left() in postgres  (Peter Nixon <listuser@peternixon.net>)
List pgsql-general
On Fri, 25 Oct 2002, Peter Nixon wrote:

> I guess I don't understand how to use it properly. can anyone give me some
> more help. When I fire off the following query (at a database of radius
> records)
>
>
> SELECT substring('CalledStationId' from 2 for 3) FROM calls WHERE

I think you'd want something like:
substring(CalledStationId from 1 for 3)

Putting it in single quotes makes it a literal, you were asking for
positions 2-4 in the literal string 'CalledStationId' => 'all'.



pgsql-general by date:

Previous
From: Bruce Momjian
Date:
Subject: Re: left() in postgres
Next
From: PD Miller
Date:
Subject: Re: left() in postgres