Please tell me how to make a login form? Here, for example, I have in the Base not one, but many users ... and how to check that the user entered into the program? For the program to determine that I logged in exactly to the account with the username admin and the password admin , and so that the program upon successful login reads the data of the user exactly from the usernames of admin , and not another one? Sorry, but I really can not correctly formulate the question. But the topic remained "How to make a login form?"

UPDATE

And in general, explain how it works and what happens when the user clicks "Enter."

    3 answers 3

     select login from users where login = 'логин' and password = 'пароль' 

    And nice, and right. And on the client check on NULL.

      January 1, the day of awesome questions =) So, you entered a username and password, a query with this data turned into a database and checked if you are such a pair (username and password) in the database, if yes - rights are granted to the user, if not - which one is displayed something warning message.

      • And how to do this check? - Angus123
      • Learn sql. - Modus
       select * from users where login = 'логин' and password = 'пароль' 

      If 1 row is returned, the data is correct. If 0, then wrong.

      • select NULL from users where login = 'login' and password = 'password' would be more correct, it seems, and more pleasant to traffic) Trifle, but nice - den94
      • select NULL from users where login = 'login' and password = 'password' would be more correct, it seems, and more pleasant to traffic) Trifle, but you yourself understood what you wrote? - Gene Ant
      • i am for sure - den94
      • one
        A sympathetic and logical would be: select count (*) ... - wind