I cannot figure out how to add a column to my SELECT query indicating whether two columns contain the same data in Oracle.
I would like to write a query like:
select column1, column2, column1=column2 from table
and, if I have this table:
+---------+---------+
| column1 | column2 |
+---------+---------+
| value1 | value1 |
| value2 | value3 |
| value4 | value4 |
+---------+---------+
get a result like:
+---------+---------+-----------------+
| column1 | column2 | column1=column2 |
+---------+---------+-----------------+
| value1 | value1 | true |
| value2 | value3 | false |
| value4 | value4 | true |
+---------+---------+-----------------+
What is the correct syntax to do this?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…