code: func (d *Datum) Cast(sc *variable.StatementContext, target *FieldType) (ad Datum, err error) {
  	if !isCastType(target.Tp) {
  		return ad, errors.Errorf("unknown cast type - %v", target)
  	}
  	return d.ConvertTo(sc, target)
  }
docs: // Cast casts datum to certain types.