mirror of
https://github.com/featurebasedb/featurebase.git
synced 2026-09-05 08:10:50 +00:00
address review of "Apply base in GroupBy on BSI"
This commit is contained in:
parent
535257af75
commit
32e47642ae
2 changed files with 4 additions and 3 deletions
|
|
@ -1799,10 +1799,11 @@ func (e *executor) executeGroupBy(ctx context.Context, index string, c *pql.Call
|
|||
if err != nil {
|
||||
return nil, errors.Wrap(err, "getting column")
|
||||
}
|
||||
if _, ok := child.Args["_field"].(string); !ok {
|
||||
fieldName, ok := child.Args["_field"].(string)
|
||||
if !ok {
|
||||
return nil, errors.Errorf("%s call must have field with valid (string) field name. Got %v of type %[2]T", child.Name, child.Args["_field"])
|
||||
}
|
||||
f := idx.Field(child.Args["_field"].(string))
|
||||
f := idx.Field(fieldName)
|
||||
if f == nil {
|
||||
return nil, ErrFieldNotFound
|
||||
}
|
||||
|
|
|
|||
|
|
@ -2997,7 +2997,7 @@ func TestExecutor_Execute_Remote_Row(t *testing.T) {
|
|||
}
|
||||
})
|
||||
|
||||
t.Run("groupbBy on ints with offset regression", func(t *testing.T) {
|
||||
t.Run("groupBy on ints with offset regression", func(t *testing.T) {
|
||||
_, err = c[0].API.CreateField(context.Background(), "i", "hint", pilosa.OptFieldTypeInt(1, 1000))
|
||||
if err != nil {
|
||||
t.Fatalf("creating field: %v", err)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue