Re: Why is this code not working?

2001-12-11 Thread Rachel Carmichael
one column (COLUMN_NAME) can't have two separate and distinct values. I think you want an "or" not an "and" in the query --- Ken Janusz <[EMAIL PROTECTED]> wrote: > When I run this code both columns I get no rows returned. When I do > a desc > on one of the tables I see both columns. So, why

RE: Why is this code not working?

2001-12-11 Thread Kevin Bass
Change the "and" in your WHERE clause to an "or". Kevin L. Bass Database Administrator Americal Corporation -Original Message- Sent: Tuesday, December 11, 2001 9:20 AM To: Multiple recipients of list ORACLE-L When I run this code both columns I get no rows returned. When I do a desc

RE: Why is this code not working?

2001-12-11 Thread Mohan, Ross
funny, i run it in my database (mutatis mutandis for column names, natch) and it works JUST FINE with AND. buti am hoping an acknowledged SQL guru will step in and say this -Original Message- Change the 'and' to 'or'. -- Please see the official ORACLE-L FAQ: h

Re: Why is this code not working?

2001-12-11 Thread Pat Hildebrand
I think you are confusing the logical and with the fact that you want both columns. Try using or in place of and (column_name = 'REGISTRATION_NUMBER' or column_name = 'DOCUMENT_NUMBER') Pat > > When I run this code both columns I get no rows returned. When I do a desc >

RE: Why is this code not working?

2001-12-11 Thread Johnston, Tim
You are trying to look for a column name be equal to two different names... I assume you want an OR instead of the AND... select table_name, column_name from dba_tab_columns where (column_name = 'REGISTRATION_NUMBER' OR column_name = 'DOCUMENT_NUMBER') -Original Message- Sent: Tuesday,

RE: Why is this code not working?

2001-12-11 Thread Mercadante, Thomas F
U - cause one row cannot have both values in the same column??? How about changing it to: select table_name, column_name from dba_tab_columns where (column_name = 'REGISTRATION_NUMBER' or column_name = 'DOCUMENT_NUMBER') or where (column_name in ('REGISTRATION_NUMBER','DOCUMENT_NUMBER'

RE: Why is this code not working?

2001-12-11 Thread Iulian . ILIES
I guess this is what you want: select table_name, column_name from dba_tab_columns where (column_name = 'REGISTRATION_NUMBER' or column_name = 'DOCUMENT_NUMBER') or select table_name, column_name from dba_tab_columns where column_name in ('REGISTRATION_NUMBER', 'DOCUMENT_NUMBER') -Origi

RE: Why is this code not working?

2001-12-11 Thread Jeroen van Sluisdam
This was returned by the mailer-daemon because of a locking problem ?? -Oorspronkelijk bericht- Van: Jeroen van Sluisdam Verzonden: dinsdag 11 december 2001 17:08 Aan: '[EMAIL PROTECTED]' Onderwerp: RE: Why is this code not working? You need an or-clause because one row

Re: Why is this code not working?

2001-12-11 Thread Dennis M. Heisler
Change the 'and' to 'or'. Ken Janusz wrote: > > When I run this code both columns I get no rows returned. When I do a desc > on one of the tables I see both columns. So, why am I not getting any data? > > select table_name, column_name > from dba_tab_columns > where > (column_name = 'REGISTR

Why is this code not working?

2001-12-11 Thread Ken Janusz
When I run this code both columns I get no rows returned. When I do a desc on one of the tables I see both columns. So, why am I not getting any data? select table_name, column_name from dba_tab_columns where (column_name = 'REGISTRATION_NUMBER' and column_name = 'DOCUMENT_NUMBER') Thanks, K