Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
mariadb
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
mariadb
Commits
54c97429
Commit
54c97429
authored
Jul 23, 2007
by
unknown
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
coding style fix : Index_hint
parent
5b0f4a17
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
15 additions
and
15 deletions
+15
-15
sql/sql_lex.cc
sql/sql_lex.cc
+3
-3
sql/sql_lex.h
sql/sql_lex.h
+7
-7
sql/sql_parse.cc
sql/sql_parse.cc
+1
-1
sql/table.cc
sql/table.cc
+2
-2
sql/table.h
sql/table.h
+2
-2
No files found.
sql/sql_lex.cc
View file @
54c97429
...
...
@@ -1770,7 +1770,7 @@ TABLE_LIST *st_select_lex_node::add_table_to_list (THD *thd, Table_ident *table,
LEX_STRING
*
alias
,
ulong
table_join_options
,
thr_lock_type
flags
,
List
<
i
ndex_hint
>
*
hints
,
List
<
I
ndex_hint
>
*
hints
,
LEX_STRING
*
option
)
{
return
0
;
...
...
@@ -2723,7 +2723,7 @@ void st_select_lex::set_index_hint_type(enum index_hint_type type,
void
st_select_lex
::
alloc_index_hints
(
THD
*
thd
)
{
index_hints
=
new
(
thd
->
mem_root
)
List
<
i
ndex_hint
>
();
index_hints
=
new
(
thd
->
mem_root
)
List
<
I
ndex_hint
>
();
}
...
...
@@ -2744,7 +2744,7 @@ void st_select_lex::alloc_index_hints (THD *thd)
bool
st_select_lex
::
add_index_hint
(
THD
*
thd
,
char
*
str
,
uint
length
)
{
return
index_hints
->
push_front
(
new
(
thd
->
mem_root
)
i
ndex_hint
(
current_index_hint_type
,
I
ndex_hint
(
current_index_hint_type
,
current_index_hint_clause
,
str
,
length
));
}
...
...
sql/sql_lex.h
View file @
54c97429
...
...
@@ -236,7 +236,7 @@ typedef uchar index_clause_map;
INDEX_HINT_MASK_ORDER)
/* Single element of an USE/FORCE/IGNORE INDEX list specified as a SQL hint */
class
i
ndex_hint
:
public
Sql_alloc
class
I
ndex_hint
:
public
Sql_alloc
{
public:
/* The type of the hint : USE/FORCE/IGNORE */
...
...
@@ -249,7 +249,7 @@ public:
*/
LEX_STRING
key_name
;
i
ndex_hint
(
enum
index_hint_type
type_arg
,
index_clause_map
clause_arg
,
I
ndex_hint
(
enum
index_hint_type
type_arg
,
index_clause_map
clause_arg
,
char
*
str
,
uint
length
)
:
type
(
type_arg
),
clause
(
clause_arg
)
{
...
...
@@ -441,7 +441,7 @@ public:
LEX_STRING
*
alias
,
ulong
table_options
,
thr_lock_type
flags
=
TL_UNLOCK
,
List
<
i
ndex_hint
>
*
hints
=
0
,
List
<
I
ndex_hint
>
*
hints
=
0
,
LEX_STRING
*
option
=
0
);
virtual
void
set_lock_for_tables
(
thr_lock_type
lock_type
)
{}
...
...
@@ -719,7 +719,7 @@ public:
LEX_STRING
*
alias
,
ulong
table_options
,
thr_lock_type
flags
=
TL_UNLOCK
,
List
<
i
ndex_hint
>
*
hints
=
0
,
List
<
I
ndex_hint
>
*
hints
=
0
,
LEX_STRING
*
option
=
0
);
TABLE_LIST
*
get_table_list
();
bool
init_nested_join
(
THD
*
thd
);
...
...
@@ -779,9 +779,9 @@ public:
/* make a list to hold index hints */
void
alloc_index_hints
(
THD
*
thd
);
/* read and clear the index hints */
List
<
i
ndex_hint
>*
pop_index_hints
(
void
)
List
<
I
ndex_hint
>*
pop_index_hints
(
void
)
{
List
<
i
ndex_hint
>
*
hints
=
index_hints
;
List
<
I
ndex_hint
>
*
hints
=
index_hints
;
index_hints
=
NULL
;
return
hints
;
}
...
...
@@ -793,7 +793,7 @@ private:
enum
index_hint_type
current_index_hint_type
;
index_clause_map
current_index_hint_clause
;
/* a list of USE/FORCE/IGNORE INDEX */
List
<
i
ndex_hint
>
*
index_hints
;
List
<
I
ndex_hint
>
*
index_hints
;
};
typedef
class
st_select_lex
SELECT_LEX
;
...
...
sql/sql_parse.cc
View file @
54c97429
...
...
@@ -5636,7 +5636,7 @@ TABLE_LIST *st_select_lex::add_table_to_list(THD *thd,
LEX_STRING
*
alias
,
ulong
table_options
,
thr_lock_type
lock_type
,
List
<
i
ndex_hint
>
*
index_hints_arg
,
List
<
I
ndex_hint
>
*
index_hints_arg
,
LEX_STRING
*
option
)
{
register
TABLE_LIST
*
ptr
;
...
...
sql/table.cc
View file @
54c97429
...
...
@@ -4642,11 +4642,11 @@ bool TABLE_LIST::process_index_hints(TABLE *table)
key_map
index_join
[
INDEX_HINT_FORCE
+
1
];
key_map
index_order
[
INDEX_HINT_FORCE
+
1
];
key_map
index_group
[
INDEX_HINT_FORCE
+
1
];
i
ndex_hint
*
hint
;
I
ndex_hint
*
hint
;
int
type
;
bool
have_empty_use_join
=
FALSE
,
have_empty_use_order
=
FALSE
,
have_empty_use_group
=
FALSE
;
List_iterator
<
i
ndex_hint
>
iter
(
*
index_hints
);
List_iterator
<
I
ndex_hint
>
iter
(
*
index_hints
);
/* initialize temporary variables used to collect hints of each kind */
for
(
type
=
INDEX_HINT_IGNORE
;
type
<=
INDEX_HINT_FORCE
;
type
++
)
...
...
sql/table.h
View file @
54c97429
...
...
@@ -754,7 +754,7 @@ public:
(TABLE_LIST::join_using_fields != NULL)
*/
class
i
ndex_hint
;
class
I
ndex_hint
;
struct
TABLE_LIST
{
TABLE_LIST
()
{}
/* Remove gcc warning */
...
...
@@ -826,7 +826,7 @@ struct TABLE_LIST
*/
TABLE_LIST
*
next_name_resolution_table
;
/* Index names in a "... JOIN ... USE/IGNORE INDEX ..." clause. */
List
<
i
ndex_hint
>
*
index_hints
;
List
<
I
ndex_hint
>
*
index_hints
;
TABLE
*
table
;
/* opened table */
uint
table_id
;
/* table id (from binlog) for opened table */
/*
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment