Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 How sql queries are parsed

Author  Topic 

sagsriv
Starting Member

1 Post

Posted - 2008-09-27 : 10:03:17
I am pretty novice in SQl. Actually I am working on some hardware improvisations of sql processors. Can anyone suggest me some book, material so that I can know how the queries inside an sql server are actually processed. I mean there should be some way in which the processors convert the queries, for example, "select * from relation1" into some machine readable forms. I suppose to convert that forms, which I expect to be more generic to some particular statements which would be understood by my processor.

GilaMonster
Master Smack Fu Yak Hacker

4507 Posts

Posted - 2008-09-27 : 11:01:26
There's a good section on that in one of the Inside SQL Server 2005 books. I think it's in the 2nd one - T-SQL Querying

Queries aren't translated into something understandable by the processor, not directly anyway. They're converted into a tree-form by the SQL parser and the algebratiser, and then the optimiser generates an execution plan for that query. That execution plan is then passed to the query processor which knows how to execute each operator in the query.

--
Gail Shaw
SQL Server MVP
Go to Top of Page
   

- Advertisement -