⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 sdbms_sql.v

📁 使用yacc的一个例子
💻 V
📖 第 1 页 / 共 5 页
字号:

	.  reduce 150


state 295
	tablenames : tablenames . ',' tablename
	select : SELECT select_list FROM tablenames . where_clause order_clause believe_clause
	where_clause : .  (192)

	','  shift 235
	WHERE  shift 169
	.  reduce 192

	where_clause goto 368


state 296
	expr : expr . OPADD term
	expr : expr . OPSUB term
	select_sub_list : select_sub_list ',' expr .  (189)

	OPADD  shift 218
	OPSUB  shift 219
	.  reduce 189


state 297
	insert_collist : '(' . fieldnames ')'

	IDENTIFIER  shift 240

	fieldname goto 241
	fieldnames goto 369


state 298
	insert : INSERT INTO tablename VALUES . insert_vallist

	'('  shift 370

	insert_vallist goto 371


state 299
	insert : INSERT INTO tablename insert_collist . VALUES insert_vallist

	VALUES  shift 372


state 300
	set_clause : fieldname . OPEQU value

	OPEQU  shift 373


state 301
	update : UPDATE tablename SET set_list .  (166)
	update : UPDATE tablename SET set_list . WHERE conditions
	set_list : set_list . ',' set_clause

	','  shift 374
	WHERE  shift 375
	.  reduce 166


state 302
	set_list : set_clause .  (169)

	.  reduce 169


state 303
	delete : YDELETE FROM tablename WHERE . conditions

	'('  shift 249
	SECLEVEL  shift 112
	OPSUB  shift 113
	OPNOT  shift 250
	OPLESS  shift 115
	YTRUE  shift 116
	YFALSE  shift 117
	IDENTIFIER  shift 118
	STRING  shift 119
	INTEGER  shift 120

	tablename goto 121
	fieldname goto 122
	seclevel goto 123
	expr goto 251
	term goto 125
	factor goto 126
	colref goto 127
	conditions goto 376
	condition goto 253
	condfactor goto 254
	comp_clause goto 255
	bool_value goto 128


state 304
	password : STRING .  (49)

	.  reduce 49


state 305
	connect_database : CONNECT username WITH PASSWORD password .  (37)

	.  reduce 37


state 306
	connect_database : CONNECT username TO dbname WITH . PASSWORD password

	PASSWORD  shift 377


state 307
	create_role : CREATE ROLE rolename AS CHILD . OF rolename

	OF  shift 378


state 308
	create_role : CREATE ROLE rolename AS PARENT . OF rolenames

	OF  shift 379


state 309
	keydef : PRIMARY . KEY keycollist

	KEY  shift 380


state 310
	coldef : fieldname . datatype
	coldef : fieldname . datatype OPNOT YNULL

	CHAR  shift 381
	INT  shift 382
	BOOL  shift 383

	datatype goto 384
	char_type goto 385
	int_type goto 386
	bool_type goto 387


state 311
	tabcollist : '(' tabcols . ')'
	tabcollist : '(' tabcols . error
	tabcols : tabcols . ',' tabcol

	')'  shift 388
	','  shift 389
	error  shift 390


state 312
	tabcols : tabcol .  (121)

	.  reduce 121


state 313
	tabcol : coldef .  (122)

	.  reduce 122


state 314
	tabcol : keydef .  (123)

	.  reduce 123


state 315
	create_table : CREATE TABLE tablename tabcollist WITH . SECLEVEL seclevel

	SECLEVEL  shift 391


state 316
	create_user : CREATE USER username WITH PASSWORD . password
	create_user : CREATE USER username WITH PASSWORD . password WITH SECLEVEL class
	create_user : CREATE USER username WITH PASSWORD . password WITH SECLEVEL seclevel

	STRING  shift 304

	password goto 392


state 317
	rolenames : rolenames ',' rolename .  (55)

	.  reduce 55


state 318
	tablenames : tablenames ',' tablename .  (111)

	.  reduce 111


state 319
	usernames : usernames ',' username .  (47)

	.  reduce 47


state 320
	rolenames : rolenames . ',' rolename
	add_user_to_role : ADD USER usernames TO rolenames .  (60)

	','  shift 234
	.  reduce 60


state 321
	rolenames : rolenames . ',' rolename
	del_user_from_role : DEL USER usernames FROM rolenames .  (61)

	','  shift 234
	.  reduce 61


state 322
	rolenames : rolenames . ',' rolename
	change_role : CHANGE USER usernames TO rolenames .  (62)

	','  shift 234
	.  reduce 62


state 323
	operation : SELECT '(' fieldnames ')' .  (86)

	.  reduce 86


state 324
	fieldnames : fieldnames ',' . fieldname

	IDENTIFIER  shift 240

	fieldname goto 393


state 325
	operation : INSERT '(' fieldnames ')' .  (88)

	.  reduce 88


state 326
	operation : UPDATE '(' fieldnames ')' .  (90)

	.  reduce 90


state 327
	operation : YDELETE '(' fieldnames ')' .  (92)

	.  reduce 92


state 328
	expr : expr . OPADD term
	expr : expr . OPSUB term
	factor : '(' expr . ')'
	factor : '(' expr . error
	comp_clause : expr . OPEQU expr
	comp_clause : expr . OPUNEQU expr
	comp_clause : expr . OPLESS expr
	comp_clause : expr . OPLESSEQU expr
	comp_clause : expr . OPMORE expr
	comp_clause : expr . OPMOREEQU expr

	')'  shift 282
	error  shift 283
	OPADD  shift 218
	OPSUB  shift 219
	OPEQU  shift 331
	OPUNEQU  shift 332
	OPLESS  shift 333
	OPLESSEQU  shift 334
	OPMORE  shift 335
	OPMOREEQU  shift 336


state 329
	conditions : conditions . OPOR condition
	condfactor : '(' conditions . ')'

	')'  shift 394
	OPOR  shift 337


state 330
	condfactor : OPNOT condfactor .  (176)

	.  reduce 176


state 331
	comp_clause : expr OPEQU . expr

	'('  shift 111
	SECLEVEL  shift 112
	OPSUB  shift 113
	OPLESS  shift 115
	YTRUE  shift 116
	YFALSE  shift 117
	IDENTIFIER  shift 118
	STRING  shift 119
	INTEGER  shift 120

	tablename goto 121
	fieldname goto 122
	seclevel goto 123
	expr goto 395
	term goto 125
	factor goto 126
	colref goto 127
	bool_value goto 128


state 332
	comp_clause : expr OPUNEQU . expr

	'('  shift 111
	SECLEVEL  shift 112
	OPSUB  shift 113
	OPLESS  shift 115
	YTRUE  shift 116
	YFALSE  shift 117
	IDENTIFIER  shift 118
	STRING  shift 119
	INTEGER  shift 120

	tablename goto 121
	fieldname goto 122
	seclevel goto 123
	expr goto 396
	term goto 125
	factor goto 126
	colref goto 127
	bool_value goto 128


state 333
	comp_clause : expr OPLESS . expr

	'('  shift 111
	SECLEVEL  shift 112
	OPSUB  shift 113
	OPLESS  shift 115
	YTRUE  shift 116
	YFALSE  shift 117
	IDENTIFIER  shift 118
	STRING  shift 119
	INTEGER  shift 120

	tablename goto 121
	fieldname goto 122
	seclevel goto 123
	expr goto 397
	term goto 125
	factor goto 126
	colref goto 127
	bool_value goto 128


state 334
	comp_clause : expr OPLESSEQU . expr

	'('  shift 111
	SECLEVEL  shift 112
	OPSUB  shift 113
	OPLESS  shift 115
	YTRUE  shift 116
	YFALSE  shift 117
	IDENTIFIER  shift 118
	STRING  shift 119
	INTEGER  shift 120

	tablename goto 121
	fieldname goto 122
	seclevel goto 123
	expr goto 398
	term goto 125
	factor goto 126
	colref goto 127
	bool_value goto 128


state 335
	comp_clause : expr OPMORE . expr

	'('  shift 111
	SECLEVEL  shift 112
	OPSUB  shift 113
	OPLESS  shift 115
	YTRUE  shift 116
	YFALSE  shift 117
	IDENTIFIER  shift 118
	STRING  shift 119
	INTEGER  shift 120

	tablename goto 121
	fieldname goto 122
	seclevel goto 123
	expr goto 399
	term goto 125
	factor goto 126
	colref goto 127
	bool_value goto 128


state 336
	comp_clause : expr OPMOREEQU . expr

	'('  shift 111
	SECLEVEL  shift 112
	OPSUB  shift 113
	OPLESS  shift 115
	YTRUE  shift 116
	YFALSE  shift 117
	IDENTIFIER  shift 118
	STRING  shift 119
	INTEGER  shift 120

	tablename goto 121
	fieldname goto 122
	seclevel goto 123
	expr goto 400
	term goto 125
	factor goto 126
	colref goto 127
	bool_value goto 128


state 337
	conditions : conditions OPOR . condition

	'('  shift 249
	SECLEVEL  shift 112
	OPSUB  shift 113
	OPNOT  shift 250
	OPLESS  shift 115
	YTRUE  shift 116
	YFALSE  shift 117
	IDENTIFIER  shift 118
	STRING  shift 119
	INTEGER  shift 120

	tablename goto 121
	fieldname goto 122
	seclevel goto 123
	expr goto 251
	term goto 125
	factor goto 126
	colref goto 127
	condition goto 401
	condfactor goto 254
	comp_clause goto 255
	bool_value goto 128


state 338
	condition : condition OPAND . condfactor

	'('  shift 249
	SECLEVEL  shift 112
	OPSUB  shift 113
	OPNOT  shift 250
	OPLESS  shift 115
	YTRUE  shift 116
	YFALSE  shift 117
	IDENTIFIER  shift 118
	STRING  shift 119
	INTEGER  shift 120

	tablename goto 121
	fieldname goto 122
	seclevel goto 123
	expr goto 251
	term goto 125
	factor goto 126
	colref goto 127
	condfactor goto 402
	comp_clause goto 255
	bool_value goto 128


state 339
	grant2 : GRANT operations where_clause ON tablename . TO rolenames
	grant2 : GRANT operations where_clause ON tablename . TO rolenames WITH GRANT OPTION

	TO  shift 403


state 340
	revoke2 : REVOKE GRANT OPTION FOR operations . where_clause FROM tablename TO rolenames
	operations : operations . ',' operation
	where_clause : .  (192)

	','  shift 168
	WHERE  shift 169
	.  reduce 192

	where_clause goto 404


state 341
	revoke2 : REVOKE operations where_clause ON tablename . FROM rolenames
	revoke2 : REVOKE operations where_clause ON tablename . FROM rolenames CASCADE
	revoke2 : REVOKE operations where_clause ON tablename . FROM rolenames RESTRICT

	FROM  shift 405


state 342
	set_child_role : SET CHILD ROLE rolenames OF . rolename

	IDENTIFIER  shift 138

	rolename goto 406


state 343
	set_parent_role : SET PARENT ROLE rolename OF . rolenames

	IDENTIFIER  shift 138

	rolename goto 144
	rolenames goto 407


state 344
	set_user_seclevel : SET SECURITY LEVEL class TO . usernames

	IDENTIFIER  shift 51

	username goto 149
	usernames goto 408


state 345
	set_user_seclevel : SET SECURITY LEVEL seclevel TO . usernames

	IDENTIFIER  shift 51

	username goto 149
	usernames goto 409


state 346
	set_table_seclevel : SET SECURITY LEVEL seclevel ON . tablenames

	IDENTIFIER  shift 132

	tablename goto 147
	tablenames goto 410


state 347
	set_allow_seclevel : SET ALLOW SECURITY LEVEL seclevel . ON tablenames TO usernames

	ON  shift 411


state 348
	set_current_seclevel : SET CURRENT SECURITY LEVEL seclevel . ON tablenames TO usernames

	ON  shift 412


state 349
	executor : ROLE '(' rolenames ')' .  (206)
	executor : ROLE '(' rolenames ')' . ',' USER '(' usernames ')'

	','  shift 413
	.  reduce 206


state 350
	security_right : SET TABLE SECURITY LEVEL .  (236)

	.  reduce 236


state 351
	security_right : SET USER SECURITY LEVEL .  (233)

	.  reduce 233


state 352
	security_right : SET USER ALLOW SECURITY . LEVEL

	LEVEL  shift 414


state 353
	security_right : SET USER CURRENT SECURITY . LEVEL

	LEVEL  shift 415


state 354
	executor : USER '(' usernames ')' .  (205)
	executor : USER '(' usernames ')' . ',' ROLE '(' rolenames ')'

	','  shift 416
	.  reduce 205


state 355
	audit2 : AUDIT objectrights ON tablename EXECUTED . BY executor

	BY  shift 417


state 356
	audit3 : AUDIT auditrights EXECUTED BY executor .  (217)

	.  reduce 217


state 357
	noaudit2 : NOAUDIT objectrights ON tablename EXECUTED . BY executor

	BY  shift 418


state 358
	noaudit3 : NOAUDIT auditrights EXECUTED BY executor .  (218)

	.  reduce 218


state 359
	colref : SECLEVEL '(' tablename '.' . fieldname ')'

	IDENTIFIER  shift 240

	fieldname goto 419


state 360
	colref : SECLEVEL '(' fieldname ')' .  (163)

	.  reduce 163


state 361
	range : '{' '}' .  (99)

	.  reduce 99


state 362
	rangeitem : STRING .  (104)

	.  reduce 104


state 363
	rangeitems : rangeitem .  (103)

	.  reduce 103


state 364
	range : '{' rangeitems . '}'
	range : '{' rangeitems . error
	rangeitems : rangeitems . ',' rangeitem

	','  shift 420
	'}'  shift 421
	error  shift 422


state 365
	seclevel : OPLESS ',' range OPMORE .  (96)

	.  reduce 96


state 366
	seclevel : OPLESS class ',' OPMORE .  (95)

	.  reduce 95


state 367
	seclevel : OPLESS class ',' range . OPMORE

	OPMORE  shift 423


state 368
	select : SELECT select_list FROM tablenames where_clause . order_clause believe_clause
	order_clause : .  (194)

	ORDER  shift 424
	.  reduce 194

	order_clause goto 425


state 369
	fieldnames : fieldnames . ',' fieldname
	insert_collist : '(' fieldnames . ')'

	')'  shift 426
	','  shift 324


state 370
	insert_vallist : '(' . vallist ')'

	'('  shift 111
	SECLEVEL  shift 112
	OPSUB  shift 113
	OPLESS  shift 115
	YTRUE  shift 116
	YFALSE  shift 117
	IDENTIFIER  shift 118
	STRING  shift 

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -