Re: [GENERAL] Method to detect certain characters in column?

2008-06-23 Thread Craig Ringer
Ian Meyer wrote: > That's entirely possible.. which is the reason for cleanup.. we're > moving to a model where members can be queried by name, and UTF-8 > isn't allowed in URLs, so we need to rename/remove users with those > types of names. Depending on your webserver, Unicode characters should b

Re: [GENERAL] Method to detect certain characters in column?

2008-06-23 Thread Ian Meyer
That's entirely possible.. which is the reason for cleanup.. we're moving to a model where members can be queried by name, and UTF-8 isn't allowed in URLs, so we need to rename/remove users with those types of names. A lot of these members are from years ago where we were on mysql with not enough e

Re: [GENERAL] Method to detect certain characters in column?

2008-06-23 Thread Tino Wildenhain
Hi Ian, Ian Meyer wrote: Ah, so I forgot to mention the one caveat to this (sorry!) was there was a ton of punctuation/spaces and other ilk.. so this is what I came up with: bco=# select name from member where not (name ~ '^[A-Za-z0-9[:punct:] ]*$'); name -- Señor

Re: [GENERAL] Method to detect certain characters in column?

2008-06-23 Thread Ian Meyer
Ah, so I forgot to mention the one caveat to this (sorry!) was there was a ton of punctuation/spaces and other ilk.. so this is what I came up with: bco=# select name from member where not (name ~ '^[A-Za-z0-9[:punct:] ]*$'); name -- Señorita Lolita Long Pig täkÃ

Re: [GENERAL] Method to detect certain characters in column?

2008-06-23 Thread Steve Atkins
On Jun 23, 2008, at 1:58 PM, Ian Meyer wrote: So I have a column that contains usernames that have characters such as Ã(c)(R), for example: fuchÃ(c)r.. is there any way to find names with non A-Za-z0-9? ... WHERE column ~* '[^a-z0-9]' Cheers, Steve -- Sent via pgsql-general mailing list

Re: [GENERAL] Method to detect certain characters in column?

2008-06-23 Thread Tom Lane
"Ian Meyer" <[EMAIL PROTECTED]> writes: > So I have a column that contains usernames that have characters such > as Ã(c)(R), for example: fuchÃ(c)r.. is there any way to find names > with non A-Za-z0-9? Hmm, none of the responses so far look right to me. How about WHERE NOT (col ~ '^[A-Z

Re: [GENERAL] Method to detect certain characters in column?

2008-06-23 Thread Alvaro Herrera
Antonio Perez wrote: > example > > SELECT name FROM  table1 where name > ~* '*Ã*' Actually this regex is flawed. It looks like a common shell "glob" pattern (I don't know the real name of these things), which is a very different and simpler animal from a regex. -- Alvaro Herrera

Re: [GENERAL] Method to detect certain characters in column?

2008-06-23 Thread Antonio Perez
Ian Meyer <[EMAIL PROTECTED]> escribió: De: Ian Meyer <[EMAIL PROTECTED]> Asunto: [GENERAL] Method to detect certain characters in column? A: pgsql-general@postgresql.org Fecha: lunes, 23 junio, 2008, 5:58 pm So I have a column that contains usernames that have characters such as Ã(c)(

Re: [GENERAL] Method to detect certain characters in column?

2008-06-23 Thread Tommy Gildseth
Ian Meyer wrote: So I have a column that contains usernames that have characters such as Ã(c)(R), for example: fuchÃ(c)r.. is there any way to find names with non A-Za-z0-9? ...WHERE col ~ '[^a-zA-Z0-9]'; Someone with a bit more regex fu can probably condense down the regex. -- Tommy Gildseth

[GENERAL] Method to detect certain characters in column?

2008-06-23 Thread Ian Meyer
So I have a column that contains usernames that have characters such as Ã(c)(R), for example: fuchÃ(c)r.. is there any way to find names with non A-Za-z0-9? Thanks in advance! - Ian -- Sent via pgsql-general mailing list (pgsql-general@postgresql.org) To make changes to your subscription: http:/