Drop unreachable error path in CREATE USER MAPPING dispatch
diff --git a/src/parser/mod.rs b/src/parser/mod.rs index 4cb438f..2a5ca2d 100644 --- a/src/parser/mod.rs +++ b/src/parser/mod.rs
@@ -5535,7 +5535,8 @@ modifier_loc ); } - self.expect_keywords(&[Keyword::USER, Keyword::MAPPING])?; + self.advance_token(); // USER + self.advance_token(); // MAPPING self.parse_create_user_mapping().map(Into::into) } else if self.parse_keyword(Keyword::USER) { self.parse_create_user(or_replace).map(Into::into)
diff --git a/tests/sqlparser_postgres.rs b/tests/sqlparser_postgres.rs index a6210db..03355e4 100644 --- a/tests/sqlparser_postgres.rs +++ b/tests/sqlparser_postgres.rs
@@ -12076,6 +12076,10 @@ "Expected: SERVER, found: EOF", ), ( + "CREATE USER MAPPING FOR", + "Expected: identifier, found: EOF", + ), + ( "CREATE USER MAPPING FOR app SERVER", "Expected: identifier, found: EOF", ),