E101: Unknown Node Type
Reference a node type that is not defined inschema.hx.
Example
- Schema:
- Query:
Solution
Define the node typeUser in schema.hx.
- Schema:
E102: Unknown Edge Type
Reference an edge type that is not defined inschema.hx.
Example
- Schema:
- Query:
Solution
Define the edge typePosted in schema.hx.
- Schema:
E103: Unknown Vector Type
Reference a vector type that is not defined inschema.hx.
Example
- Schema:
- Query:
Solution
Define the vector typeDocument in schema.hx.
- Schema:
E105: Invalid Identifier
Use an invalid identifier inquery.hx.
Example
Out is a reserved keyword so it cannot be used as a variable or a parameter name.
- Query:
Solution
Rename the variable or parameter to a valid identifier.- Query:
E202: Field Not in Schema
Reference a field that is not defined inschema.hx for a given item type.
Example
The fieldusername is not defined in schema.hx for the User item type.
- Schema:
- Query:
Solution
Define the fieldusername in schema.hx for the User item type.
- Schema:
E204: Reserved Field Name
Use a reserved field name inschema.hx or query.hx.
Example
The fieldid is a reserved field name for any item type.
- Schema:
Solution
Rename the field to a valid identifier.- Schema:
E205: Type Mismatch
Occurs when the type of a value you’re providing doesn’t match the expected field type defined inschema.hx.
Example
- Schema:
- Query:
Solution
Change type ofsomeField to String or U32.
- Schema:
- Query:
E207: Invalid Edge Type for Item
Use an edge type that exists inschema.hx but is not valid for the specific item type you’re working with.
Example
In this example, theCreated edge exists. However, it goes from User to Post, not from Post to User. Therefore, it is not valid for an Out step from a Post node.
- Schema:
- Query:
Solution
Change the traversal to use theIn step instead of the Out step.
- Query:
E301: Variable Not in Scope
Reference a variable that is not currently in scope or has not been declared.Example
The variableuserId is not declared.
- Query:
Solution
Declare the variableuserId as a parameter before using it.
- Query:
E302: Variable Previously Declared
Declare a variable that has already been declared in the current scope.Example
In this example, the variableuserId is declared twice.
- Query:
Solution
Use a different variable name.- Query:
E304: Missing Item Type
An item type is required but not provided in your query.Example
TheUser item type is required but not provided.
- Query:
Solution
Specify the required item type within the< and > brackets after the traversal step in your query.
- Query:
E305: Missing Parameter
A required parameter is missing from a function call or operation.Example
TheSearchV function is called without the k parameter which is required to limit the number of results.
- Query:
Solution
Provide all required parameters for functions and operations.- Query:
E401: MCP Single Value Requirement
An MCP (Model Context Protocol) query returns multiple values when only a single value is expected.Example
The MCP query returns multiple users, but MCP expects a single value.- Query:
Solution
Ensure MCP queries return exactly one value.- Query:
E501: Invalid Date
Provide a date value that cannot be parsed or is in an invalid format.Example
The date value"2023-99-99" is invalid and cannot be parsed.
- Schema:
- Query:
Solution
Ensure the date value is in the correct format.- Query:
E601: Invalid Traversal
Attempt to perform a malformed traversal. Note: This error is not currently emitted by the compiler.Example
- Query:
Solution
- Query:
E602: Invalid Step
Use a step that is not valid in the current context.Example
TheOutE<Knows> step results in edges, but the Out step can only be used on nodes.
- Schema:
- Query:
Solution
- Query:
E604: Update Restriction
Performing an update operation on something other than nodes or edges.Example
The update step is used on a vector type which is not allowed yet.- Query:
E611: Missing To ID
Create an edge without specifying the target node ID.Example
TheAddE step is used without specifying the To parameter.
- Query:
Solution
Provide bothFrom and To node IDs when creating edges.
- Query:
E612: Missing From ID
Create an edge without specifying the source node ID.Example
TheAddE step is used without specifying the From parameter.
- Query:
Solution
Provide bothFrom and To node IDs when creating edges.
- Query:
E621: Invalid Boolean Comparison
Apply a boolean comparison operation to a type that doesn’t support it.Example
- Schema:
- Query:
Solution
Ensure boolean operations are used on values that result in primitive types like booleans, numbers, or strings.- Query:
E622: Type Mismatch in Comparison
Compare a property with a value of a different type.Example
- Schema:
- Query:
Solution
- Query:
E631: Incomplete Range
Define a range without both start and end values.Example
- Query:
Solution
- Query:
E632: Invalid Range Order
The start value of a range is greater than or equal to the end value. This error is only emitted by the compiler when both start and end values are provided as literals. A runtime error will be emitted if the range is not valid at runtime.Example
The start value is greater than the end value.- Query:
Solution
Ensure range start value is less than end value.- Query:
E633: Non-Integer Range Index
Use a non-integer value as an index in a range operation.Example
The range index is a float value which is not allowed.- Query:
Solution
Use integer values for range indices or set variable types to integer types.- Query:
E641: Closure Position Restriction
Place a closure operation in a position other than the last step of a traversal.Example
The closure is not at the end of the traversal.- Query:
Solution
Move the closure to the last step of the traversal.- Query:
E642: Object Position Restriction
Place an object operation in a position other than the last step of a traversal.Example
The object is not at the end of the traversal.- Query:
Solution
Move the object to the last step of the traversal.- Query:
E643: Field Previously Excluded
Access or include a field that has been previously excluded in the traversal.Example
The email field is excluded in the traversal, but is being included.- Query:
Solution
Remove the exclusion or access the field after the exclusion.- Query:
E644: Exclude Position Restriction
Place an exclude operation in a position other than the last step of a traversal or the step before an object remapping or closure remapping step.Example
The exclude step is used before theOut<Knows> step which is not allowed.
- Query:
Solution
Move the exclude step to the last step of the traversal or the step before an object remapping or closure remapping step.- Query:
E645
Define an object remapping with no fields.Example
- Schema:
- Query:
Solution
- Query:
E651: Non-Iterable Variable
Use a non-iterable variable in an iteration context.Example
The parametername is not iterable, so it cannot be used in an iteration context.
- Query:
Solution
Ensure variables used in iterations are collections or arrays.- Query:
E652: Invalid Field Access
Access a field that doesn’t exist on the inner type of an iterable variable.Example
Thenonexistent_field field doesn’t exist on the inner type of the userData iterable variable.
- Query:
Solution
Ensure to only access fields that exist on the inner type.- Query:
E653: Non-Object Inner Type
The inner type of an iterable variable is not an object type, preventing field access or object destructuring.Example
Thenames variable contains strings, not objects, so field access is not allowed.
- Query:
Solution
Ensure iterable contains object types for field access.- Query: