How to compare two fields of identical values but different size?

0

I have a database where you have fields of the same name but with different sizes

I need to choose the field with the largest VARCHAR. How can I do this?

    
asked by anonymous 19.01.2018 / 15:13

1 answer

2

I think if you wanted to do a SELECT , then just in SELECT in large letters:

SELECT CNES FROM Table

Or for example if you want to select the two only:

SELECT cnes,CNES FROM Table

But I think for reasons like this it would be better to change the column name to something easier to distinguish.

EDIT : I did not notice it was a question about Oracle SQL, but I estimate it to be the same. Correct me if I'm wrong! :)

    
19.01.2018 / 15:33