Skip to content

Commit 02c8112

Browse files
committed
Sort statement grammars alphabethically
1 parent 82a3616 commit 02c8112

File tree

1 file changed

+134
-134
lines changed

1 file changed

+134
-134
lines changed

src/parser.pegjs

Lines changed: 134 additions & 134 deletions
Original file line numberDiff line numberDiff line change
@@ -78,188 +78,188 @@ non_transaction_statement
7878
/ &postgres x:statement_postgres { return x; }
7979

8080
statement_sqlite
81-
= compound_select_stmt
82-
/ insert_stmt
83-
/ update_stmt
84-
/ delete_stmt
85-
/ create_view_stmt
86-
/ drop_view_stmt
81+
= alter_table_stmt
82+
/ analyze_stmt
83+
/ attach_database_stmt
84+
/ compound_select_stmt
8785
/ create_index_stmt
88-
/ drop_index_stmt
89-
/ reindex_stmt
90-
/ create_trigger_stmt
91-
/ drop_trigger_stmt
9286
/ create_table_stmt
87+
/ create_trigger_stmt
88+
/ create_view_stmt
89+
/ delete_stmt
90+
/ detach_database_stmt
91+
/ drop_index_stmt
9392
/ drop_table_stmt
94-
/ alter_table_stmt
95-
/ analyze_stmt
93+
/ drop_trigger_stmt
94+
/ drop_view_stmt
9695
/ explain_stmt
97-
/ attach_database_stmt
98-
/ detach_database_stmt
99-
/ vacuum_stmt
96+
/ insert_stmt
10097
/ pragma_stmt
98+
/ reindex_stmt
99+
/ update_stmt
100+
/ vacuum_stmt
101101

102102
statement_mysql
103-
= compound_select_stmt
104-
/ insert_stmt
105-
/ update_stmt
106-
/ delete_stmt
107-
/ truncate_stmt
108-
/ create_view_stmt
109-
/ drop_view_stmt
110-
/ create_index_stmt
111-
/ drop_index_stmt
103+
= alter_schema_stmt
104+
/ alter_table_stmt
112105
/ alter_view_stmt
113-
/ rename_table_stmt
114-
/ create_trigger_stmt
115-
/ drop_trigger_stmt
106+
/ analyze_stmt
107+
/ break_stmt
108+
/ call_stmt
109+
/ case_stmt
110+
/ compound_select_stmt
111+
/ continue_stmt
112+
/ create_index_stmt
116113
/ create_schema_stmt
117-
/ drop_schema_stmt
118-
/ alter_schema_stmt
119114
/ create_table_stmt
120-
/ drop_table_stmt
121-
/ alter_table_stmt
122-
/ labeled$block_stmt
115+
/ create_trigger_stmt
116+
/ create_view_stmt
117+
/ deallocate_stmt
123118
/ declare_stmt
124-
/ set_stmt
119+
/ delete_stmt
120+
/ drop_index_stmt
121+
/ drop_schema_stmt
122+
/ drop_table_stmt
123+
/ drop_trigger_stmt
124+
/ drop_view_stmt
125+
/ execute_stmt
126+
/ explain_stmt
125127
/ if_stmt
126-
/ case_stmt
128+
/ insert_stmt
129+
/ labeled$block_stmt
127130
/ labeled$loop_stmt
128131
/ labeled$repeat_stmt
129132
/ labeled$while_stmt
130-
/ break_stmt
131-
/ continue_stmt
132-
/ call_stmt
133-
/ return_stmt
134-
/ analyze_stmt
135-
/ explain_stmt
136133
/ prepare_stmt
137-
/ deallocate_stmt
138-
/ execute_stmt
134+
/ rename_table_stmt
135+
/ return_stmt
136+
/ set_stmt
137+
/ truncate_stmt
138+
/ update_stmt
139139

140140
statement_bigquery
141-
= compound_select_stmt
142-
/ insert_stmt
143-
/ update_stmt
144-
/ delete_stmt
145-
/ truncate_stmt
146-
/ merge_stmt
147-
/ create_view_stmt
148-
/ drop_view_stmt
149-
/ create_index_stmt
150-
/ drop_index_stmt
141+
= alter_bi_capacity_stmt
142+
/ alter_capacity_stmt
143+
/ alter_organization_stmt
144+
/ alter_project_stmt
145+
/ alter_reservation_stmt
146+
/ alter_schema_stmt
147+
/ alter_table_stmt
151148
/ alter_view_stmt
149+
/ assert_stmt
150+
/ break_stmt
151+
/ call_stmt
152+
/ case_stmt
153+
/ compound_select_stmt
154+
/ continue_stmt
155+
/ create_bigquery_entity_stmt
152156
/ create_function_stmt
153-
/ drop_function_stmt
157+
/ create_index_stmt
154158
/ create_procedure_stmt
155-
/ drop_procedure_stmt
159+
/ create_row_access_policy_stmt
156160
/ create_schema_stmt
157-
/ drop_schema_stmt
158-
/ alter_schema_stmt
159161
/ create_table_stmt // CREATE TABLE must be matched after CREATE [TABLE] FUNCTION
160-
/ drop_table_stmt
161-
/ alter_table_stmt
162-
/ labeled$block_stmt
162+
/ create_view_stmt
163163
/ declare_stmt
164-
/ set_stmt
164+
/ delete_stmt
165+
/ drop_bigquery_entity_stmt
166+
/ drop_function_stmt
167+
/ drop_index_stmt
168+
/ drop_procedure_stmt
169+
/ drop_row_access_policy_stmt
170+
/ drop_schema_stmt
171+
/ drop_table_stmt
172+
/ drop_view_stmt
173+
/ execute_immediate_stmt
174+
/ export_data_stmt
175+
/ grant_stmt
165176
/ if_stmt
166-
/ case_stmt
177+
/ insert_stmt
178+
/ labeled$block_stmt
179+
/ labeled$for_stmt
167180
/ labeled$loop_stmt
168181
/ labeled$repeat_stmt
169182
/ labeled$while_stmt
170-
/ labeled$for_stmt
171-
/ break_stmt
172-
/ continue_stmt
173-
/ call_stmt
174-
/ return_stmt
183+
/ load_data_stmt
184+
/ merge_stmt
175185
/ raise_stmt
176-
/ grant_stmt
186+
/ return_stmt
177187
/ revoke_stmt
178-
/ execute_immediate_stmt
179-
/ create_bigquery_entity_stmt
180-
/ drop_bigquery_entity_stmt
181-
/ create_row_access_policy_stmt
182-
/ drop_row_access_policy_stmt
183-
/ alter_organization_stmt
184-
/ alter_project_stmt
185-
/ alter_bi_capacity_stmt
186-
/ alter_capacity_stmt
187-
/ alter_reservation_stmt
188-
/ assert_stmt
189-
/ export_data_stmt
190-
/ load_data_stmt
188+
/ set_stmt
189+
/ truncate_stmt
190+
/ update_stmt
191191

192192
statement_postgres
193-
= compound_select_stmt
194-
/ insert_stmt
195-
/ update_stmt
196-
/ delete_stmt
197-
/ truncate_stmt
198-
/ merge_stmt
199-
/ create_view_stmt
200-
/ drop_view_stmt
201-
/ create_index_stmt
202-
/ drop_index_stmt
203-
/ alter_index_stmt
193+
= alter_default_privileges_stmt
194+
/ alter_domain_stmt
195+
/ alter_function_stmt
204196
/ alter_index_all_in_tablespace_stmt
205-
/ reindex_stmt
197+
/ alter_index_stmt
198+
/ alter_policy_stmt
199+
/ alter_procedure_stmt
200+
/ alter_publication_stmt
201+
/ alter_role_stmt
202+
/ alter_schema_stmt
203+
/ alter_sequence_stmt
204+
/ alter_table_all_in_tablespace_stmt
205+
/ alter_table_stmt
206+
/ alter_trigger_stmt
207+
/ alter_type_stmt
206208
/ alter_view_stmt
207-
/ refresh_materialized_view_stmt
209+
/ analyze_stmt
210+
/ call_stmt
211+
/ comment_stmt
212+
/ compound_select_stmt
213+
/ create_domain_stmt
214+
/ create_extension_stmt
208215
/ create_function_stmt
209-
/ drop_function_stmt
210-
/ alter_function_stmt
216+
/ create_index_stmt
217+
/ create_policy_stmt
211218
/ create_procedure_stmt
212-
/ drop_procedure_stmt
213-
/ alter_procedure_stmt
214-
/ alter_table_all_in_tablespace_stmt
219+
/ create_publication_stmt
220+
/ create_role_stmt
215221
/ create_schema_stmt
216-
/ drop_schema_stmt
217-
/ alter_schema_stmt
218222
/ create_sequence_stmt
219-
/ alter_sequence_stmt
220-
/ drop_sequence_stmt
223+
/ create_subscription_stmt
224+
/ create_table_stmt // CREATE TABLE must be matched after CREATE TABLE FUNCTION
221225
/ create_trigger_stmt
222-
/ alter_trigger_stmt
223-
/ drop_trigger_stmt
224226
/ create_type_stmt
225-
/ alter_type_stmt
226-
/ drop_type_stmt
227-
/ create_domain_stmt
228-
/ alter_domain_stmt
227+
/ create_view_stmt
228+
/ deallocate_stmt
229+
/ delete_stmt
230+
/ do_stmt
229231
/ drop_domain_stmt
230-
/ create_role_stmt
231-
/ alter_role_stmt
232-
/ drop_role_stmt
233-
/ set_role_stmt
234-
/ reset_role_stmt
235-
/ create_policy_stmt
236-
/ alter_policy_stmt
232+
/ drop_extension_stmt
233+
/ drop_function_stmt
234+
/ drop_index_stmt
237235
/ drop_policy_stmt
238-
/ create_table_stmt // CREATE TABLE must be matched after CREATE TABLE FUNCTION
236+
/ drop_procedure_stmt
237+
/ drop_publication_stmt
238+
/ drop_role_stmt
239+
/ drop_schema_stmt
240+
/ drop_sequence_stmt
241+
/ drop_subscription_stmt
239242
/ drop_table_stmt
240-
/ alter_table_stmt
241-
/ grant_stmt
242-
/ revoke_stmt
243-
/ alter_default_privileges_stmt
244-
/ analyze_stmt
243+
/ drop_trigger_stmt
244+
/ drop_type_stmt
245+
/ drop_view_stmt
246+
/ execute_stmt
245247
/ explain_stmt
248+
/ grant_stmt
249+
/ insert_stmt
250+
/ merge_stmt
246251
/ prepare_stmt
247-
/ deallocate_stmt
248-
/ execute_stmt
249-
/ call_stmt
250-
/ do_stmt
252+
/ refresh_materialized_view_stmt
253+
/ reindex_stmt
254+
/ reset_parameter_stmt
255+
/ reset_role_stmt
256+
/ revoke_stmt
251257
/ set_parameter_stmt
258+
/ set_role_stmt
252259
/ set_time_zone_parameter_stmt
253-
/ reset_parameter_stmt
254260
/ show_parameter_stmt
255-
/ create_extension_stmt
256-
/ drop_extension_stmt
257-
/ create_publication_stmt
258-
/ alter_publication_stmt
259-
/ drop_publication_stmt
260-
/ create_subscription_stmt
261-
/ drop_subscription_stmt
262-
/ comment_stmt
261+
/ truncate_stmt
262+
/ update_stmt
263263

264264
dml_statement
265265
= compound_select_stmt

0 commit comments

Comments
 (0)