Oracle Development
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsDatabasesOracle Development

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old April 21st, 2006, 06:25 PM
bzborow1 bzborow1 is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2003
Location: Canada
Posts: 84 bzborow1 User rank is Corporal (100 - 500 Reputation Level)bzborow1 User rank is Corporal (100 - 500 Reputation Level)bzborow1 User rank is Corporal (100 - 500 Reputation Level)bzborow1 User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: 17 h 51 m 9 sec
Reputation Power: 7
Regexp_replace....

Hi all,

I've got a question about how i can format data within Oracle queries as opposed to code. I have the following query

Code:
SELECT REGEXP_REPLACE(NAME, '[^a-zA-Z0-9]', ' ')
FROM LIB.TABLE;


But I get an ORA-00904: Invalid column name error. I really can't figure out why this would be as there are plenty of examples on the web using REGEXP_REPLACE in a similar fashion. I'm using ORACLE 10g.

Thanks in advance!

Reply With Quote
  #2  
Old April 23rd, 2006, 10:32 AM
jim mcnamara jim mcnamara is offline
......@.........
Dev Shed Beginner (1000 - 1499 posts)
 
Join Date: Jun 2004
Posts: 1,308 jim mcnamara User rank is Sergeant Major (2000 - 5000 Reputation Level)jim mcnamara User rank is Sergeant Major (2000 - 5000 Reputation Level)jim mcnamara User rank is Sergeant Major (2000 - 5000 Reputation Level)jim mcnamara User rank is Sergeant Major (2000 - 5000 Reputation Level)jim mcnamara User rank is Sergeant Major (2000 - 5000 Reputation Level)jim mcnamara User rank is Sergeant Major (2000 - 5000 Reputation Level) 
Time spent in forums: 1 Week 3 Days 6 h 19 m 24 sec
Reputation Power: 48
ORA-0904 means LIB.TABLE deosn't have a column called 'NAME'

Reply With Quote
  #3  
Old April 24th, 2006, 10:13 AM
bzborow1 bzborow1 is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Feb 2003
Location: Canada
Posts: 84 bzborow1 User rank is Corporal (100 - 500 Reputation Level)bzborow1 User rank is Corporal (100 - 500 Reputation Level)bzborow1 User rank is Corporal (100 - 500 Reputation Level)bzborow1 User rank is Corporal (100 - 500 Reputation Level) 
Time spent in forums: 17 h 51 m 9 sec
Reputation Power: 7
I thought that as well but when I run.

Code:
SELECT NAME
FROM LIB.TABLE


I get 1000 names returned.

EDIT: I apologize I just found out our test server is 10g, but our production server is 8i...don't ask me why.

Reply With Quote
Reply

Viewing: Dev Shed ForumsDatabasesOracle Development > Regexp_replace....


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 5 hosted by Hostway
Stay green...Green IT