From: | "phd9110" <phd9110(at)cs(dot)nchu(dot)edu(dot)tw> |
---|---|
To: | <pgsql-hackers(at)postgresql(dot)org> |
Subject: | rte in set_plan_rel_pathlist() |
Date: | 2003-10-24 04:33:57 |
Message-ID: | 002801c399e8$0a376210$6c0d788c@husky |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
hi:
in allpath.c ,the set_plan_rel_pathlist() function has a parameter of RangeTblEntry type.
what does we use this varaible to do ?
i doesn't see any code in this function using it .
In optimizer module, it look like that we can get most information from Query . Is it right ?
so , what time use Query? what time use RangeTblEntry? Are there any rule?
Kao
136 /*
137 * set_plain_rel_pathlist
138 * Build access paths for a plain relation (no subquery, no inheritance)
139 */
140 static void
141 set_plain_rel_pathlist(Query *root, RelOptInfo *rel, RangeTblEntry *rte)
142 {
143 /* Mark rel with estimated output rows, width, etc */
144 set_baserel_size_estimates(root, rel);
145
146 /*
147 * Generate paths and add them to the rel's pathlist.
148 *
149 * Note: add_path() will discard any paths that are dominated by another
150 * available path, keeping only those paths that are superior along at
151 * least one dimension of cost or sortedness.
152 */
153
154 /* Consider sequential scan */
155 add_path(rel, create_seqscan_path(root, rel));
156
157 /* Consider TID scans */
158 create_tidscan_paths(root, rel);
159
160 /* Consider index paths for both simple and OR index clauses */
161 create_index_paths(root, rel);
162
163 /* create_index_paths must be done before create_or_index_paths */
164 create_or_index_paths(root, rel);
165
166 /* Now find the cheapest of the paths for this rel */
167 set_cheapest(rel);
168 }
169
--
From | Date | Subject | |
---|---|---|---|
Next Message | Bruce Momjian | 2003-10-24 04:39:29 | Re: Broken Constraint Checking in Functions |
Previous Message | Curt Sampson | 2003-10-24 04:29:59 | Re: Broken Constraint Checking in Functions |