![]() | |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
This question pertains to the Query Plan for views. Assume that I have a table of 10,000 widgets (widgets_table) with a primary key on the identity column widget_id. Now, assume I have a view (widgets_view) defined as: select * from widgets_table The plan for the following query (against the view) puts 10,000 rows into play: select * from widgets_view where widgets_id = 5000 The plan for the following query (against the table) only puts 1 row into play: select * from widgets_table where widgets_id = 5000 How can I hit the view but get the efficiencies of a table? Are there hints, compiler options, configuration options, etc... that can be used to influence the query plan of the view? |
#3
| |||
| |||
|
|
This question pertains to the Query Plan for views. Assume that I have a table of 10,000 widgets (widgets_table) with a primary key on the identity column widget_id. Now, assume I have a view (widgets_view) defined as: select * from widgets_table The plan for the following query (against the view) puts 10,000 rows into play: select * from widgets_view where widgets_id = 5000 The plan for the following query (against the table) only puts 1 row into play: select * from widgets_table where widgets_id = 5000 How can I hit the view but get the efficiencies of a table? Are there hints, compiler options, configuration options, etc... that can be used to influence the query plan of the view? |
#4
| |||
| |||
|
|
This question pertains to the Query Plan for views. Assume that I have a table of 10,000 widgets (widgets_table) with a primary key on the identity column widget_id. Now, assume I have a view (widgets_view) defined as: select * from widgets_table The plan for the following query (against the view) puts 10,000 rows into play: select * from widgets_view where widgets_id = 5000 The plan for the following query (against the table) only puts 1 row into play: select * from widgets_table where widgets_id = 5000 How can I hit the view but get the efficiencies of a table? Are there hints, compiler options, configuration options, etc... that can be used to influence the query plan of the view? |
#5
| |||
| |||
|
|
This question pertains to the Query Plan for views. Assume that I have a table of 10,000 widgets (widgets_table) with a primary key on the identity column widget_id. Now, assume I have a view (widgets_view) defined as: select * from widgets_table The plan for the following query (against the view) puts 10,000 rows into play: select * from widgets_view where widgets_id = 5000 The plan for the following query (against the table) only puts 1 row into play: select * from widgets_table where widgets_id = 5000 How can I hit the view but get the efficiencies of a table? Are there hints, compiler options, configuration options, etc... that can be used to influence the query plan of the view? |
#6
| |||
| |||
|
|
This question pertains to the Query Plan for views. Assume that I have a table of 10,000 widgets (widgets_table) with a primary key on the identity column widget_id. Now, assume I have a view (widgets_view) defined as: select * from widgets_table The plan for the following query (against the view) puts 10,000 rows into play: select * from widgets_view where widgets_id = 5000 The plan for the following query (against the table) only puts 1 row into play: select * from widgets_table where widgets_id = 5000 How can I hit the view but get the efficiencies of a table? Are there hints, compiler options, configuration options, etc... that can be used to influence the query plan of the view? |
#7
| |||
| |||
|
|
This question pertains to the Query Plan for views. Assume that I have a table of 10,000 widgets (widgets_table) with a primary key on the identity column widget_id. Now, assume I have a view (widgets_view) defined as: select * from widgets_table The plan for the following query (against the view) puts 10,000 rows into play: select * from widgets_view where widgets_id = 5000 The plan for the following query (against the table) only puts 1 row into play: select * from widgets_table where widgets_id = 5000 How can I hit the view but get the efficiencies of a table? Are there hints, compiler options, configuration options, etc... that can be used to influence the query plan of the view? |
#8
| |||
| |||
|
|
This question pertains to the Query Plan for views. Assume that I have a table of 10,000 widgets (widgets_table) with a primary key on the identity column widget_id. Now, assume I have a view (widgets_view) defined as: select * from widgets_table The plan for the following query (against the view) puts 10,000 rows into play: select * from widgets_view where widgets_id = 5000 The plan for the following query (against the table) only puts 1 row into play: select * from widgets_table where widgets_id = 5000 How can I hit the view but get the efficiencies of a table? Are there hints, compiler options, configuration options, etc... that can be used to influence the query plan of the view? |
#9
| |||
| |||
|
|
This question pertains to the Query Plan for views. Assume that I have a table of 10,000 widgets (widgets_table) with a primary key on the identity column widget_id. Now, assume I have a view (widgets_view) defined as: select * from widgets_table The plan for the following query (against the view) puts 10,000 rows into play: select * from widgets_view where widgets_id = 5000 The plan for the following query (against the table) only puts 1 row into play: select * from widgets_table where widgets_id = 5000 How can I hit the view but get the efficiencies of a table? Are there hints, compiler options, configuration options, etc... that can be used to influence the query plan of the view? |
#10
| |||
| |||
|
|
This question pertains to the Query Plan for views. Assume that I have a table of 10,000 widgets (widgets_table) with a primary key on the identity column widget_id. Now, assume I have a view (widgets_view) defined as: select * from widgets_table The plan for the following query (against the view) puts 10,000 rows into play: select * from widgets_view where widgets_id = 5000 The plan for the following query (against the table) only puts 1 row into play: select * from widgets_table where widgets_id = 5000 How can I hit the view but get the efficiencies of a table? Are there hints, compiler options, configuration options, etc... that can be used to influence the query plan of the view? |
![]() |
| Thread Tools | |
| Display Modes | |
| |