New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

expression: remove type assertion on `types.DatumRow`. #5005

Merged
merged 4 commits into from Nov 7, 2017

Conversation

Projects
None yet
3 participants
@coocood
Member

coocood commented Nov 4, 2017

So we can change the implementation of types.Row from types.DatumRow to chunk.Row.

expression: remove type assertion on `types.DatumRow`.
So we can change the implement of `types.DatumRow` to `chunk.Row`.
res, err := val.ToFloat64(sc)
return res, err != nil, errors.Trace(err)
}
return val.GetFloat64(), false, nil
if col.GetType().Tp == mysql.TypeFloat {
val, isNull := row.GetFloat32(col.Index)

This comment has been minimized.

@winkyao

winkyao Nov 4, 2017

Member

need distinguish float32?

@winkyao

winkyao Nov 4, 2017

Member

need distinguish float32?

This comment has been minimized.

@coocood

coocood Nov 5, 2017

Member

float32 is stored in 4 bytes in chunk

@coocood

coocood Nov 5, 2017

Member

float32 is stored in 4 bytes in chunk

@winkyao

This comment has been minimized.

Show comment
Hide comment
@winkyao

winkyao Nov 5, 2017

Member

Please fix conflict

Member

winkyao commented Nov 5, 2017

Please fix conflict

@winkyao winkyao added the status/LGT1 label Nov 5, 2017

Show outdated Hide outdated util/types/row.go

coocood added some commits Nov 5, 2017

@coocood

This comment has been minimized.

Show comment
Hide comment
@coocood
Member

coocood commented Nov 7, 2017

@zz-jason
PTAL

@zz-jason

LGTM

@zz-jason zz-jason merged commit 1aa2a69 into pingcap:master Nov 7, 2017

4 checks passed

ci/circleci Your tests passed on CircleCI!
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
jenkins-ci-tidb/build Jenkins job succeeded.
Details
license/cla Contributor License Agreement is signed.
Details

@coocood coocood deleted the coocood:rows-assertion branch Nov 7, 2017

spongedu added a commit to spongedu/tidb that referenced this pull request Nov 7, 2017

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment