-
Notifications
You must be signed in to change notification settings - Fork 15
Open
Labels
featureA new functionalityA new functionalityquestionFurther information is requestedFurther information is requested
Description
Follows #350
Update conditions support field number ids (moreover, due to compatibility with older Tarantool, all non-number identificators are converted to number ones, see
Lines 591 to 618 in 3f2db88
function utils.convert_operations(user_operations, space_format) | |
local converted_operations = {} | |
for _, operation in ipairs(user_operations) do | |
if type(operation[2]) == 'string' then | |
local field_id | |
for fieldno, field_format in ipairs(space_format) do | |
if field_format.name == operation[2] then | |
field_id = fieldno | |
break | |
end | |
end | |
if field_id == nil then | |
return nil, ParseOperationsError:new( | |
"Space format doesn't contain field named %q", operation[2]) | |
end | |
table.insert(converted_operations, { | |
operation[1], field_id, operation[3] | |
}) | |
else | |
table.insert(converted_operations, operation) | |
end | |
end | |
return converted_operations | |
end |
I don't remember hearing any user requests about field id support, so I'll put a question label here. On the other hand, I don't see any reasons against adding this (like there were for space id in #255) since we expect space schema to be the same everywhere.
ArtDu and bitgorbovsky
Metadata
Metadata
Assignees
Labels
featureA new functionalityA new functionalityquestionFurther information is requestedFurther information is requested