I don't get this one!
Can you tell me what is the result if you do
select * from tblusr;
without any WHERE-clause ??
If you find a result with the statement you posted, you should find the same line(s) with the statement above.
I hope both username and password fields show the values '-' when you execute your statement !! Otherwise, you really have trouble in your code and we should look at it more closely.
Below, you see the results of my tests with the information you provided.
I guess your results look similar ??.
(Is there a reason why you use single quotes for username value and double quotes for password value ?)
mysql> desc tblusr;
+----------+-------------+------+-----+---------+-------+
| Field | Type | Null | Key | Default | Extra |
+----------+-------------+------+-----+---------+-------+
| usr_id | int(11) | | PRI | 0 | |
| username | varchar(20) | YES | | - | |
| password | varchar(20) | YES | | NULL | |
+----------+-------------+------+-----+---------+-------+
3 rows in set (0.00 sec)
mysql> insert into tblusr (usr_id, password) values (7, '');
Query OK, 1 row affected (0.00 sec)
mysql> select * from tblusr;
+--------+----------+----------+
| usr_id | username | password |
+--------+----------+----------+
| 1 | user1 | passwd1 |
| 2 | user2 | passwd2 |
| 3 | user3 | passwd3 |
| 4 | - | - |
| 5 | | |
| 6 | | |
| 7 | - | |
+--------+----------+----------+
7 rows in set (0.00 sec)
mysql> select * from tblusr where username='-' and password='-';
+--------+----------+----------+
| usr_id | username | password |
+--------+----------+----------+
| 4 | - | - |
+--------+----------+----------+
1 row in set (0.01 sec)