Tuesday 22 September 2009

LOGIN OPERATION - LIBRARY SYSTEM

A little bird told me that a login form should be incorporated into the Library System that TESDA will ask you to design during the CoC1 exam. This is easy to implement. Really, no kidding.

You're gonna need a new form with 2 textboxes in it and 2 command buttons. Name the textboxes as tbUsername and tbPassword and the command buttons as cbLogin and cbCancel. When the user presses cbLogin, your application should connect to the database and check for records with matching username and password as those inputted on the textboxes. Here's the SQL for this:

SELECT mem_name, mem_id FROM members, accounts WHERE members.mem_id = accounts.mem_id and mem_username = '(insert tbUsername.Text here)' AND mem_password = '(insert tbPassword.Text here)'

To explain, you're simply telling SQL to get the member name and the member id of the record from the members database where the members id matches the member id in the accounts database who's username and password matches those inputted by the user in your textboxes.

4 comments:

  1. sir kindly provide more detail process of this library system. after the member logging in what the system can do?

    Thank you very much

    rusty

    ReplyDelete
  2. i think the one who posted of this blog may tell also that they need to take the exam first for they what to have start with.. yah that is easy to tell that is easy.. how about follwing instructions? is that the part of exam? YES!

    ReplyDelete
  3. 5 tables lng ang ginamit mo d2..

    ReplyDelete
  4. This comment has been removed by the author.

    ReplyDelete