~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/show.cc

  • Committer: Padraig O'Sullivan
  • Date: 2009-06-17 19:39:27 UTC
  • mto: This revision was merged to the branch mainline in revision 1067.
  • Revision ID: osullivan.padraig@gmail.com-20090617193927-sdsgtvbw3mz8dgrq
Added some doxygen comments. Added a new boolean variable to the
InfoSchemaClass to indicate whether optimizations specific to the fillTable
method which used to be called get_open_tables can be performed or not.

Show diffs side-by-side

added added

removed removed

Lines of Context:
4044
4044
      /*if (session->lex->describe &&
4045
4045
          (table_list->schema_table->fill_table != get_all_tables))
4046
4046
        continue;*/
 
4047
      if (session->lex->describe &&
 
4048
          (table_list->schema_table->isOptimizationPossible() != true))
 
4049
      {
 
4050
        continue;
 
4051
      }
4047
4052
 
4048
4053
      /*
4049
4054
        If schema table is already processed and
4378
4383
 
4379
4384
static InfoSchemaTable char_set_table("CHARACTER_SETS",
4380
4385
                                      charsets_fields_info,
4381
 
                                      -1, -1, 0, 0,
 
4386
                                      -1, -1, false, false, 0,
4382
4387
                                      &char_set_methods);
4383
4388
static InfoSchemaTable collations_table("COLLATIONS",
4384
4389
                                        collation_fields_info,
4385
 
                                        -1, -1, 0, 0,
 
4390
                                        -1, -1, false, false, 0,
4386
4391
                                        &collations_methods);
4387
4392
static InfoSchemaTable
4388
4393
  coll_char_set_table("COLLATION_CHARACTER_SET_APPLICABILITY",
4389
4394
                      coll_charset_app_fields_info,
4390
 
                      -1, -1, 0, 0,
 
4395
                      -1, -1, false, false, 0,
4391
4396
                      &coll_char_methods);
4392
4397
static InfoSchemaTable columns_table("COLUMNS",
4393
4398
                                     columns_fields_info,
4394
 
                                     1, 2, 0, OPTIMIZE_I_S_TABLE,
 
4399
                                     1, 2, false, true, OPTIMIZE_I_S_TABLE,
4395
4400
                                     &columns_methods);
4396
4401
static InfoSchemaTable global_stat_table("GLOBAL_STATUS",
4397
4402
                                         variables_fields_info,
4398
 
                                         -1, -1, 0, 0,
 
4403
                                         -1, -1, false, false, 0,
4399
4404
                                         &status_methods);
4400
4405
static InfoSchemaTable global_var_table("GLOBAL_VARIABLES",
4401
4406
                                        variables_fields_info,
4402
 
                                        -1, -1, 0, 0,
 
4407
                                        -1, -1, false, false, 0,
4403
4408
                                        &variables_methods);
4404
4409
static InfoSchemaTable key_col_usage_table("KEY_COLUMN_USAGE",
4405
4410
                                           key_column_usage_fields_info,
4406
 
                                           4, 5, 0, OPEN_TABLE_ONLY,
 
4411
                                           4, 5, false, true, OPEN_TABLE_ONLY,
4407
4412
                                           &key_col_usage_methods);
4408
4413
static InfoSchemaTable open_tab_table("OPEN_TABLES",
4409
4414
                                      open_tables_fields_info,
4410
 
                                      -1, -1, 1, 0,
 
4415
                                      -1, -1, true, false, 0,
4411
4416
                                      &open_tables_methods);
4412
4417
static InfoSchemaTable plugins_table("PLUGINS",
4413
4418
                                     plugin_fields_info,
4414
 
                                     -1, -1, 0, 0,
 
4419
                                     -1, -1, false, false, 0,
4415
4420
                                     &plugins_methods);
4416
4421
static InfoSchemaTable process_list_table("PROCESSLIST",
4417
4422
                                          processlist_fields_info,
4418
 
                                          -1, -1, 0, 0,
 
4423
                                          -1, -1, false, false, 0,
4419
4424
                                          &processlist_methods);
4420
4425
static InfoSchemaTable ref_constrain_table("REFERENTIAL_CONSTRAINTS",
4421
4426
                                           referential_constraints_fields_info,
4422
 
                                           1, 9, 0, OPEN_TABLE_ONLY,
 
4427
                                           1, 9, false, true, OPEN_TABLE_ONLY,
4423
4428
                                           &ref_constraints_methods);
4424
4429
static InfoSchemaTable schemata_table("SCHEMATA",
4425
4430
                                      schema_fields_info,
4426
 
                                      1, -1, 0, 0,
 
4431
                                      1, -1, false, false, 0,
4427
4432
                                      &schemata_methods);
4428
4433
static InfoSchemaTable sess_stat_table("SESSION_STATUS",
4429
4434
                                       variables_fields_info,
4430
 
                                       -1, -1, 0, 0,
 
4435
                                       -1, -1, false, false, 0,
4431
4436
                                       &status_methods);
4432
4437
static InfoSchemaTable sess_var_table("SESSION_VARIABLES",
4433
4438
                                      variables_fields_info,
4434
 
                                      -1, -1, 0, 0,
 
4439
                                      -1, -1, false, false, 0,
4435
4440
                                      &variables_methods);
4436
4441
static InfoSchemaTable stats_table("STATISTICS",
4437
4442
                                   stat_fields_info,
4438
 
                                   1, 2, 0,
 
4443
                                   1, 2, false, true,
4439
4444
                                   OPEN_TABLE_ONLY|OPTIMIZE_I_S_TABLE,
4440
4445
                                   &stats_methods);
4441
4446
static InfoSchemaTable status_table("STATUS",
4442
4447
                                    variables_fields_info,
4443
 
                                    -1, -1, 1, 0,
 
4448
                                    -1, -1, true, false, 0,
4444
4449
                                    &status_methods);
4445
4450
static InfoSchemaTable tables_table("TABLES",
4446
4451
                                    tables_fields_info,
4447
 
                                    1, 2, 0, OPTIMIZE_I_S_TABLE,
 
4452
                                    1, 2, false, true, OPTIMIZE_I_S_TABLE,
4448
4453
                                    &tables_methods);
4449
4454
static InfoSchemaTable tab_constrain_table("TABLE_CONSTRAINTS",
4450
4455
                                           table_constraints_fields_info,
4451
 
                                           3, 4, 0, OPEN_TABLE_ONLY,
 
4456
                                           3, 4, false, true, OPEN_TABLE_ONLY,
4452
4457
                                           &tab_constraints_methods);
4453
4458
static InfoSchemaTable tab_names_table("TABLE_NAMES",
4454
4459
                                       table_names_fields_info,
4455
 
                                       1, 2, 1, 0,
 
4460
                                       1, 2, true, true, 0,
4456
4461
                                       &tab_names_methods);
4457
4462
static InfoSchemaTable var_table("VARIABLES",
4458
4463
                                 variables_fields_info,
4459
 
                                 -1, -1, 1, 0,
 
4464
                                 -1, -1, true, false, 0,
4460
4465
                                 &variables_methods);
4461
4466
 
4462
4467
/*