Process of SQL
Apr 13, 2022
SQL statements are executed in 3 steps.
- Parse
- Validate
- Generate/Execute access plan
- Parse: In this step, the SQL query will break into words, and then it will check for syntax errors and spelling errors.
- Validate: It checks queries against the system catalog. Like, table name in the statement exists in the database or not, the columns demanded by the user in the statement exist in the table or not. In short in this step the items demanded in the statement will be checked against the system.
- Generate/Execute access plan: Finally, the DBMS generates an access plan so that queries may be accessed quickly and easily. The access plan is a binary representation of statements in 0 and 1 format for executing database results. Then it will proceed to carry out the access strategy in a timely and efficient manner