Skip to content

Commit

Permalink
ddl, kv: address comments.
Browse files Browse the repository at this point in the history
  • Loading branch information
qiuyesuifeng committed Oct 12, 2015
1 parent bd6fde4 commit faad0de
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion ddl/alter.go
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ const (
type ColumnPosition struct {
// ColumnPositionNone | ColumnPositionFirst | ColumnPositionAfter
Type int
// RelativeColumn is the column which is after the newly added column if type is ColumnPositionAfter.
// RelativeColumn is the column which is before the newly added column if type is ColumnPositionAfter.
RelativeColumn string
}

Expand Down
4 changes: 2 additions & 2 deletions ddl/ddl.go
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ func setColumnFlagWithConstraint(colMap map[string]*column.Col, v *coldef.TableC
continue
}
c.Flag |= mysql.PriKeyFlag
// primary key can not be NULL.
// Primary key can not be NULL.
c.Flag |= mysql.NotNullFlag
}
case coldef.ConstrUniq, coldef.ConstrUniqIndex, coldef.ConstrUniqKey:
Expand Down Expand Up @@ -457,7 +457,7 @@ func (d *ddl) addColumn(ctx context.Context, schema model.CIStr, tbl table.Table
// Insert position is after the mentioned column.
position = c.Offset + 1
}
// TODO: Set constraint
// TODO: set constraint
col, _, err := d.buildColumnAndConstraint(position, spec.Column)
if err != nil {
return errors.Trace(err)
Expand Down
2 changes: 1 addition & 1 deletion kv/union_store.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ import (
type conditionType int

const (
// conditionIfNotExist means the condition is not exist.
// conditionIfNotExist means the condition doesn't exist.
conditionIfNotExist conditionType = iota + 1
// conditionIfEqual means the condition is equals.
conditionIfEqual
Expand Down

0 comments on commit faad0de

Please sign in to comment.