Components of database engine in SQL server

The relational database server in SQL server has two main components: Relational and Storage engine. From SQL server 7.0 onwards Microsoft made an important change and used 'OLEDB' API to made communication between them.










Relational and Storage engine play very important role during query execution in SQL server.

There are following functions covered by Relational and Storage engine during query execution in SQL server -

1. Parse the SQL statements 
Scan the SQL statements,
Break into logical units such as keywords, identifier, parameters, others,
Break down the SQL statements into smaller units of operations,
Compilation and syntax check of SQL statement

2. Optimization of Query execution plan
Query optimizer determines and combine the various steps involved to run SQL query which is know as Execution Plan,

3. Executing serially all logical operations defined in the execution plan
Once execution plan is done, relational engine starts process to run all logical units in a sequential manner.

4. Request to Storage engine
Relational engine requests to Storage engine using OLEDB API,
Relational engine uses OLEDB API to get each row set from row sets. It requests to Storage engine to open. Storage engine transfer the data from the data buffers to the relational database.

5. Combining the row set and pass the result to user 
Finally Relational engine combine all the rows from row set and send back to the user.

Post a Comment

0 Comments