File tree Expand file tree Collapse file tree 2 files changed +4
-1
lines changed Expand file tree Collapse file tree 2 files changed +4
-1
lines changed Original file line number Diff line number Diff line change @@ -238,6 +238,9 @@ var (
238
238
// ErrEventDoesNotExist is returned when an event does not exist.
239
239
ErrEventDoesNotExist = errors .NewKind ("Event '%s' does not exist" )
240
240
241
+ // ErrUndeclaredVariable is return when an undeclared variable is used.
242
+ ErrUndeclaredVariable = errors .NewKind ("Undeclared variable: '%s'" )
243
+
241
244
// ErrUnknownEvent is returned when a query references an event that doesn't exist
242
245
ErrUnknownEvent = errors .NewKind ("Unknown event '%s'" )
243
246
Original file line number Diff line number Diff line change @@ -752,7 +752,7 @@ func (b *Builder) buildInto(inScope *scope, into *ast.Into) {
752
752
vars [i ] = expression .NewUserVar (strings .TrimPrefix (val .String (), "@" ))
753
753
} else {
754
754
if inScope .proc == nil {
755
- err := sql .ErrExternalProcedureMissingContextParam .New (val .String ())
755
+ err := sql .ErrUndeclaredVariable .New (val .String ())
756
756
b .handleErr (err )
757
757
}
758
758
col , ok := inScope .proc .GetVar (val .String ())
You can’t perform that action at this time.
0 commit comments