• Post Reply Bookmark Topic Watch Topic
  • New Topic

last generated slno

 
preethi Ayyappan
Ranch Hand
Posts: 518
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I need to get the last generated serial numberfrom my sql database.I tried the following my sql query directly in database.it is working.but when i use this in my servlet program,it is showing error.

error:

column usr_login_time not found


my database is correct and i am having the field usr_login_time in table time.when i use some other query like

I am able to print the time.I dont know why MAX(slno) is not working in my servlet code.

please help me to solve this.

Thanks.
 
Campbell Ritchie
Marshal
Posts: 53140
124
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
You aren't selecting usr_login_time in your query.

I think this thread would sit better in the JDBC forum, so I shall move it there.

CR
 
Happiness is not a goal ... it's a by-product of a life well lived - Eleanor Roosevelt. Tiny ad:
the new thread boost feature: great for the advertiser and smooth for the coderanch user
https://coderanch.com/t/674455/Thread-Boost-feature
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!