~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to sql/sql_select.cc

  • Committer: Monty Taylor
  • Date: 2008-07-09 15:52:52 UTC
  • mto: (77.6.1 glibclient-merge)
  • mto: This revision was merged to the branch mainline in revision 112.
  • Revision ID: monty@inaugust.com-20080709155252-lnzmxxje1g40z3a7
Warning fixes. 

Show diffs side-by-side

added added

removed removed

Lines of Context:
169
169
                                 table_map used_table,
170
170
                                 bool exclude_expensive_cond);
171
171
static Item* part_of_refkey(TABLE *form,Field *field);
172
 
uint find_shortest_key(TABLE *table, const key_map *usable_keys);
173
172
static bool test_if_skip_sort_order(JOIN_TAB *tab,ORDER *order,
174
173
                                    ha_rows select_limit, bool no_changes,
175
174
                                    const key_map *map);
4667
4666
 
4668
4667
static bool
4669
4668
update_ref_and_keys(THD *thd, DYNAMIC_ARRAY *keyuse,JOIN_TAB *join_tab,
4670
 
                    uint tables, COND *cond, COND_EQUAL *cond_equal,
 
4669
                    uint tables, COND *cond,
 
4670
                    COND_EQUAL *cond_equal __attribute__((__unused__)),
4671
4671
                    table_map normal_tables, SELECT_LEX *select_lex,
4672
4672
                    SARGABLE_PARAM **sargables)
4673
4673
{
5019
5019
                 table_map remaining_tables,
5020
5020
                 uint      idx,
5021
5021
                 double    record_count,
5022
 
                 double    read_time)
 
5022
                 double    read_time __attribute__((__unused__)))
5023
5023
{
5024
5024
  KEYUSE *best_key=         0;
5025
5025
  uint best_max_key_part=   0;
6369
6369
  Find how much space the prevous read not const tables takes in cache.
6370
6370
*/
6371
6371
 
6372
 
static void calc_used_field_length(THD *thd, JOIN_TAB *join_tab)
 
6372
static void calc_used_field_length(THD *thd __attribute__((__unused__)),
 
6373
                                   JOIN_TAB *join_tab)
6373
6374
{
6374
6375
  uint null_fields,blobs,fields,rec_length;
6375
6376
  Field **f_ptr,*field;
10797
10798
    new_created field
10798
10799
*/
10799
10800
 
10800
 
static Field *create_tmp_field_from_item(THD *thd, Item *item, TABLE *table,
 
10801
static Field *create_tmp_field_from_item(THD *thd __attribute__((__unused__)),
 
10802
                                         Item *item, TABLE *table,
10801
10803
                                         Item ***copy_func, bool modify_item,
10802
10804
                                         uint convert_blob_length)
10803
10805
{
10920
10922
    new_created field
10921
10923
*/
10922
10924
 
10923
 
Field *create_tmp_field_for_schema(THD *thd, Item *item, TABLE *table)
 
10925
Field *create_tmp_field_for_schema(THD *thd __attribute__((__unused__)),
 
10926
                                   Item *item, TABLE *table)
10924
10927
{
10925
10928
  if (item->field_type() == MYSQL_TYPE_VARCHAR)
10926
10929
  {
10973
10976
                        Item ***copy_func, Field **from_field,
10974
10977
                        Field **default_field,
10975
10978
                        bool group, bool modify_item,
10976
 
                        bool table_cant_handle_bit_fields,
 
10979
                        bool table_cant_handle_bit_fields __attribute__((__unused__)),
10977
10980
                        bool make_copy_field,
10978
10981
                        uint convert_blob_length)
10979
10982
{
16531
16534
static ORDER *
16532
16535
create_distinct_group(THD *thd, Item **ref_pointer_array,
16533
16536
                      ORDER *order_list, List<Item> &fields,
16534
 
                      List<Item> &all_fields,
16535
 
                      bool *all_order_by_fields_used)
 
16537
                      List<Item> &all_fields __attribute__((__unused__)),
 
16538
                      bool *all_order_by_fields_used)
16536
16539
{
16537
16540
  List_iterator<Item> li(fields);
16538
 
  Item *item, **orig_ref_pointer_array= ref_pointer_array;
 
16541
  Item *item;
16539
16542
  ORDER *order,*group,**prev;
16540
16543
 
16541
16544
  *all_order_by_fields_used= 1;
17436
17439
  @param select   pointer to st_select_lex which subselects joins we will free
17437
17440
*/
17438
17441
 
17439
 
void free_underlaid_joins(THD *thd, SELECT_LEX *select)
 
17442
void free_underlaid_joins(THD *thd __attribute__((__unused__)),
 
17443
                          SELECT_LEX *select)
17440
17444
{
17441
17445
  for (SELECT_LEX_UNIT *unit= select->first_inner_unit();
17442
17446
       unit;
18469
18473
static void print_join(THD *thd,
18470
18474
                       String *str,
18471
18475
                       List<TABLE_LIST> *tables,
18472
 
                       enum_query_type query_type)
 
18476
                       enum_query_type query_type __attribute__((__unused__)))
18473
18477
{
18474
18478
  /* List is reversed => we should reverse it before using */
18475
18479
  List_iterator_fast<TABLE_LIST> ti(*tables);