Re: [SQL] text vs varchar

2002-06-18 Thread Josh Goldberg
I have no trouble indexing TEXT datatype in postgres-7.x - Original Message - From: "Josh Berkus" <[EMAIL PROTECTED]> > Yes. You can't index TEXT because it's of potentially unlimited length. ---(end of broadcast)--- TIP 2: you can get

Re: [SQL] date_part

2002-06-18 Thread Josh Berkus
Rudi, select to_char(date_column, 'Month'); See similar under "Formatting Function" in the docs. -- -Josh Berkus ---(end of broadcast)--- TIP 3: if posting/reading through Usenet, please send an appropriate subscribe-nomail command to [EMAIL PR

Re: [SQL] text vs varchar

2002-06-18 Thread Wei Weng
On Tue, 2002-06-18 at 18:59, Josh Berkus wrote: > Wei, > > > Is there any disadvantage of using TEXT datatype as opposed to a VARCHAR > > datatype with a maximum length, especially when I do searches on them? > > Yes. You can't index TEXT because it's of potentially unlimited length. > > -- >

Re: [SQL] text vs varchar

2002-06-18 Thread Michelle Murrain
On Tue, 2002-06-18 at 18:07, Wei Weng wrote: > Is there any disadvantage of using TEXT datatype as opposed to a VARCHAR > datatype with a maximum length, especially when I do searches on them? There is one big disadvantage that I've found, but might be utterly unimportant to you. Some application

Re: [SQL] text vs varchar

2002-06-18 Thread Josh Berkus
Wei, > Is there any disadvantage of using TEXT datatype as opposed to a VARCHAR > datatype with a maximum length, especially when I do searches on them? Yes. You can't index TEXT because it's of potentially unlimited length. -- -Josh Berkus ---(end of broadcast)-

[SQL] text vs varchar

2002-06-18 Thread Wei Weng
Is there any disadvantage of using TEXT datatype as opposed to a VARCHAR datatype with a maximum length, especially when I do searches on them? Thanks -- Wei Weng Network Software Engineer KenCast Inc. ---(end of broadcast)--- TIP 3: if postin

Re: [SQL] Users

2002-06-18 Thread Bruno Wolff III
On Tue, Jun 18, 2002 at 00:46:59 +0100, Andy Pearce <[EMAIL PROTECTED]> wrote: > Hi, > > This may be the wrong forum, but I'm sure someone can help! > > I'm writing a VB application that uses PostgreSQL as the database backend. Is it >common practice to create a user id in pgsql for each user

Re: [SQL] Request for builtin function: Double_quote

2002-06-18 Thread Josh Berkus
Chris, Tom: Yes, thank you Chris, I meant a builtin SQL function. > > Given the amount of qoute nesting we do in Postgres, I thought that > we need a > > function that handles automatic doubling of quotes within strings. > I've > > written one in PL/pgSQL (below). I'd really love to see thi

Re: [SQL] Request for builtin function: Double_quote

2002-06-18 Thread Tom Lane
Josh Berkus <[EMAIL PROTECTED]> writes: > Given the amount of qoute nesting we do in Postgres, I thought that we need a > function that handles automatic doubling of quotes within strings. I've > written one in PL/pgSQL (below). I'd really love to see this turned into a > builtin C function.

Re: [SQL] function text_ge(text, text), how to use on version 7.2

2002-06-18 Thread Achilleus Mantzios
On Tue, 18 Jun 2002 [EMAIL PROTECTED] wrote: > Hello there > > I use the function text_ge(text, text) under version 7.03 and it was just > fine. After upgrading to version 7.2 this function doesn't work anymore. It is quite possible that text_ge uses local encodings. However I think it is worki

[SQL] function text_ge(text, text), how to use on version 7.2

2002-06-18 Thread juerg . rietmann
Hello there I use the function text_ge(text, text) under version 7.03 and it was just fine. After upgrading to version 7.2 this function doesn't work anymore. this statement shows all the records even if the greatest year is 2002 in ul_datum : select * from userlog where text_ge(ul_datum, '01.01

Re: [SQL] Limiting database size

2002-06-18 Thread Ulrich Sprick
Hi Mauricio Novell, and i think windows and unix as well, have the disk quota feature. The disk size assigned to a user can be limited. There should also be warning levels in order to get the sysadmin noticed about a user running out of space before it's too late. Try on a os related newsgroup, t

Re: [SQL] Request for builtin function: Double_quote

2002-06-18 Thread Christoph Haller
Josh, I'm not sure what you mean by 'builtin C function'. There is one already size_t PQescapeString (char *to, const char *from, size_t length); Or do you mean a String Function like substring(string [from integer] [for integer]) I would rather call it 'builtin sql function'. Regards, C