~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/item/subselect.cc

  • Committer: Brian Aker
  • Date: 2010-05-19 00:35:41 UTC
  • mto: This revision was merged to the branch mainline in revision 1542.
  • Revision ID: brian@gaz-20100519003541-7ecxcuwv9klvzi8l
JOIN -> Join rename

Show diffs side-by-side

added added

removed removed

Lines of Context:
90
90
  if (unit->item)
91
91
  {
92
92
    /*
93
 
      Item can be changed in JOIN::prepare while engine in JOIN::optimize
 
93
      Item can be changed in JOIN::prepare while engine in Join::optimize
94
94
      => we do not copy old_engine here
95
95
    */
96
96
    engine= unit->item->engine;
172
172
}
173
173
 
174
174
Item_subselect::trans_res
175
 
Item_subselect::select_transformer(JOIN *)
 
175
Item_subselect::select_transformer(Join *)
176
176
{
177
177
  return(RES_OK);
178
178
}
497
497
  Make rollback for it, or special name resolving mode in 5.0.
498
498
*/
499
499
Item_subselect::trans_res
500
 
Item_singlerow_subselect::select_transformer(JOIN *join)
 
500
Item_singlerow_subselect::select_transformer(Join *join)
501
501
{
502
502
  if (changed)
503
503
    return(RES_OK);
977
977
*/
978
978
 
979
979
Item_subselect::trans_res
980
 
Item_in_subselect::single_value_transformer(JOIN *join,
 
980
Item_in_subselect::single_value_transformer(Join *join,
981
981
                                            const Comp_creator *func)
982
982
{
983
983
  Select_Lex *select_lex= join->select_lex;
1159
1159
*/
1160
1160
 
1161
1161
Item_subselect::trans_res
1162
 
Item_in_subselect::single_value_in_to_exists_transformer(JOIN * join, const Comp_creator *func)
 
1162
Item_in_subselect::single_value_in_to_exists_transformer(Join * join, const Comp_creator *func)
1163
1163
{
1164
1164
  Select_Lex *select_lex= join->select_lex;
1165
1165
 
1335
1335
 
1336
1336
 
1337
1337
Item_subselect::trans_res
1338
 
Item_in_subselect::row_value_transformer(JOIN *join)
 
1338
Item_in_subselect::row_value_transformer(Join *join)
1339
1339
{
1340
1340
  Select_Lex *select_lex= join->select_lex;
1341
1341
  uint32_t cols_num= left_expr->cols();
1412
1412
*/
1413
1413
 
1414
1414
Item_subselect::trans_res
1415
 
Item_in_subselect::row_value_in_to_exists_transformer(JOIN * join)
 
1415
Item_in_subselect::row_value_in_to_exists_transformer(Join * join)
1416
1416
{
1417
1417
  Select_Lex *select_lex= join->select_lex;
1418
1418
  Item *having_item= 0;
1610
1610
 
1611
1611
 
1612
1612
Item_subselect::trans_res
1613
 
Item_in_subselect::select_transformer(JOIN *join)
 
1613
Item_in_subselect::select_transformer(Join *join)
1614
1614
{
1615
1615
  return select_in_like_transformer(join, Eq_creator::instance());
1616
1616
}
1638
1638
*/
1639
1639
 
1640
1640
Item_subselect::trans_res
1641
 
Item_in_subselect::select_in_like_transformer(JOIN *join, const Comp_creator *func)
 
1641
Item_in_subselect::select_in_like_transformer(Join *join, const Comp_creator *func)
1642
1642
{
1643
1643
  Select_Lex *current= session->lex->current_select, *up;
1644
1644
  const char *save_where= session->where;
1841
1841
 
1842
1842
bool Item_in_subselect::init_left_expr_cache()
1843
1843
{
1844
 
  JOIN *outer_join= NULL;
 
1844
  Join *outer_join= NULL;
1845
1845
 
1846
1846
  outer_join= unit->outer_select()->join;
1847
1847
  if (! outer_join || ! outer_join->tables || ! outer_join->join_tab)
1880
1880
 
1881
1881
 
1882
1882
Item_subselect::trans_res
1883
 
Item_allany_subselect::select_transformer(JOIN *join)
 
1883
Item_allany_subselect::select_transformer(Join *join)
1884
1884
{
1885
1885
  exec_method= IN_TO_EXISTS;
1886
1886
  if (upper_item)
2017
2017
{
2018
2018
  if (prepared)
2019
2019
    return 0;
2020
 
  join= new JOIN(session, select_lex->item_list,
 
2020
  join= new Join(session, select_lex->item_list,
2021
2021
                 select_lex->options | SELECT_NO_UNLOCK, result);
2022
2022
  if (!join || !result)
2023
2023
    return 1; /* Fatal error is set already. */
3077
3077
  Cleanup performed after each PS execution.
3078
3078
 
3079
3079
  @detail
3080
 
  Called in the end of JOIN::prepare for PS from Item_subselect::cleanup.
 
3080
  Called in the end of Join::prepare for PS from Item_subselect::cleanup.
3081
3081
*/
3082
3082
 
3083
3083
void subselect_hash_sj_engine::cleanup()
3122
3122
    /*
3123
3123
      TODO:
3124
3124
      - Unlock all subquery tables as we don't need them. To implement this
3125
 
        we need to add new functionality to JOIN::join_free that can unlock
 
3125
        we need to add new functionality to Join::join_free that can unlock
3126
3126
        all tables in a subquery (and all its subqueries).
3127
3127
      - The temp table used for grouping in the subquery can be freed
3128
3128
        immediately after materialization (yet it's done together with