Win a copy of Design for the Mind this week in the Design forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

SQL/Access97 Question

 
Craig Snowbarger
Ranch Hand
Posts: 38
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I'm having a problem with the code excerpt below. I'm using the text entered in a textfield named tUsername as variable "u" in my query statement to validate password and username. Everything works fine when the username and password actually exist in the database. The problem I have is when the username or password does not exist in the database, the while "(rs.next())" statement is completely skipped. I assume this is happening b/c, when the query returns "" there is nothing for "(rs.next())" to go to next. Does anybody have any suggestions?
Thanks in advance,
Craig Snowbarger

fixed the final UBB tag from [ CODE ] to [ /CODE ]
[This message has been edited by Frank Carver (edited March 21, 2001).]
 
Thomas Paul
mister krabs
Ranch Hand
Posts: 13974
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

Do you really need this in a while loop?
------------------
Moderator of the JDBC Forum
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic