Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: Creating a table and a constraint

Re: Creating a table and a constraint

From: Hans Forbrich <forbrich_at_yahoo.net>
Date: Fri, 26 Mar 2004 19:03:19 GMT
Message-ID: <X7%8c.21682$Ct5.19566@edtnps89>


JellyBum wrote:  

> i understand that, but how does a compare follow from that. Ive found that
> you cant do say name1=name2 in most versions of oracle, mine including.

If I understand your question, you are not really concerned about 'creating' a table with such a constraint as 'selecting both values from a self-referencing table'.

Assuming that is correct, are you comfortable with 'joins'? And being able to qualify the column name in a join using the 'table.column' syntax? If so, remember that you can alias a table and change this to 'table_alias.column' and then create and reference to the table twice using two aliases in your select statement.

HTH
/Hans Received on Fri Mar 26 2004 - 13:03:19 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US