Hi
I have table in oracle database with below records.
LoginID | FirstName | DN | Manager DN |
---|
USER100 | User | uid=user100,dc=company,dc=com | uid=user101,dc=company,dc=com |
User102 | userx | (null) | (null) |
I am looking for query which can give the output enclosed with double quotes for columns DN and Manager DN. I have written the query which works as long as DN and Manager DN columns are not null. But there are situations where these 2 columns can be null. I don't want to put double quotes when DN or ManagerDN is null. Can someone help me with the query
select loginid, firstname,
'"'||dn||'"',
'"'||manager_dn||'"',
from user