Re: Doubt in parser - Mailing list pgsql-hackers

From Michael Glaesemann
Subject Re: Doubt in parser
Date
Msg-id 9BC66B41-80E2-4E18-82E0-8B4DE392B49F@myrealbox.com
Whole thread Raw
In response to Doubt in parser  (Dhanaraj <Dhanaraj.M@Sun.COM>)
Responses Re: Doubt in parser
List pgsql-hackers
On Feb 16, 2006, at 21:37 , Dhanaraj wrote:

> hi
>
> currently i looking at the postgres src code. I saw the scanner and  
> parser implemetations at two different places (src/backend/parser/   
> and  /src/bakend/bootstrp). Can anybody tell me the purpose of  
> having two phases?? or will this help to parse the queries at  
> different levels?

AFAIK, I don't think the code is exactly the same (though I haven't  
checked). The bootstrap code is used to get the PostgreSQL server  
started: there is a considerable amount of information stored in the  
system catalogs that the server needs to use. The server needs access  
to a scanner/parser to be able to read this information. The  
bootstrap code provides the server with enough knowledge to get  
started. The backend parser and scanner is more feature-filled.

Someone please feel free to step in and correct me if I'm off base :)

Michael Glaesemann
grzm myrealbox com





pgsql-hackers by date:

Previous
From: Andrew - Supernews
Date:
Subject: Re: bug in PG_VERSION_NUM patch
Next
From: Tom Lane
Date:
Subject: Re: Doubt in parser