Query : select Nvl(max(dholdingdate),trunc(sysdate)) as dholdingdate from tblcdsldatesnew where tblcdsldatesnew.nfirmnumber = 0and tblcdsldatesnew.ntransactionexist = 0 and dholdingdate <= sysdate Is NSDL C Connection string : Data Source=192.168.200.212/dpcdsl;User Id=CLLVL;Password=;Connection Lifetime = 120; Connection Timeout = 60; Query Result : Error :- ORA-01005: null password given; logon denied / Data Source=192.168.200.212/dpcdsl;User Id=CLLVL;Password=;Connection Lifetime = 120; Connection Timeout = 60;