mirror of
https://github.com/featurebasedb/featurebase.git
synced 2026-09-07 17:15:56 +00:00
re-apply single equals fix
This commit is contained in:
parent
6d6b2de374
commit
064d267d1e
1 changed files with 13 additions and 0 deletions
13
executor.go
13
executor.go
|
|
@ -4384,6 +4384,19 @@ func (e *executor) translateCall(c *pql.Call, index string, columnKeys map[strin
|
|||
if err := fieldValidateValue(f, arg); err != nil {
|
||||
return nil, errors.Wrap(err, "validating field parameter value")
|
||||
}
|
||||
if c.Name == "Row" {
|
||||
switch f.Type() {
|
||||
case FieldTypeInt, FieldTypeDecimal:
|
||||
if _, ok := arg.(*pql.Condition); !ok {
|
||||
// This is workaround to support pql.ASSIGN ('=') as condition ('==') for int and decimal fields.
|
||||
arg = &pql.Condition{
|
||||
Op: pql.EQ,
|
||||
Value: arg,
|
||||
}
|
||||
c.Args[field] = arg
|
||||
}
|
||||
}
|
||||
}
|
||||
switch arg := arg.(type) {
|
||||
case string:
|
||||
if translation, ok := indexRows[field][arg]; ok {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue