Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
public
/
sequelize
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Snippets
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
不要怂,就是干,撸起袖子干!
Commit 5d7f96eb
authored
Dec 09, 2011
by
sdepold
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
first steps for addIndex
1 parent
96a69c2c
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
26 additions
and
0 deletions
lib/connectors/mysql/query-generator.js
lib/connectors/mysql/query-generator.js
View file @
5d7f96e
...
...
@@ -184,6 +184,32 @@ var QueryGenerator = module.exports = {
return
Utils
.
_
.
template
(
query
)(
replacements
)
},
addIndexQuery
:
function
(
tableName
,
attributes
,
options
)
{
// var sql = [
// "CREATE <%= indicesType %> INDEX <%= name %>",
// "<%= indexType %> ON <%= tableName %> <%= columns %>",
// "<%= parser %>"
// ].join(' ')
// return Utils._.template(sql)({
// indicesType: options.indicesType || '',
// name: options.indexName,
// indexType: options.indexType ? 'USING ' + options.indexType : undefined,
// })
/*
CREATE [UNIQUE|FULLTEXT|SPATIAL] INDEX index_name
[USING index_type]
ON tbl_name (index_col_name,...)
[WITH PARSER parser_name]
index_col_name:
col_name [(length)] [ASC | DESC]
*/
},
/*
Takes something and transforms it into values of a where condition.
*/
...
...
Write
Preview
Markdown
is supported
Attach a file
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 post a comment