1
Answer

sql query problem

darma teja

darma teja

11y
630
1
Hi All,

I am getting ID AS NULL. But I have seen in the database that there is ID with customer name Reliance-tech.

select ID
from Customer
where customername= 'Reliance-tech';

Thanks in advance

Darma
Answers (1)
0
Jignesh Trivedi
NA 61k 14.2m 11y

Hi,

As per my knowledge, select query return null if and only if data is not present.
here it may be you customer name does not exist in data base. it might be change to spell mistake or other mistake....

try..
select ID from Customer
where customername like 'Reliance%';

Accepted