# mysql-a_custom_database **Repository Path**: wang_atao/mysql-a_custom_database ## Basic Information - **Project Name**: mysql-a_custom_database - **Description**: A course experiment of Principles of Compilation. Based on Flex && Bison - **Primary Language**: Unknown - **License**: GPL-3.0 - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2021-07-06 - **Last Updated**: 2021-07-07 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README ## 1.Introduce * This is a course experiment of Principles of Compilation. * This project includes lexical analysis and Grammatical analysis and Syntax-directed translation. * This project is based on Flex && Bison. * Flex is used for lexical analysis. * Bison is used for Grammatical analysis. * Syntax-directed translation is completed in mysql.y. * You can implement Syntax-directed translation just by specifying C statement after each production. ## 2.Start * git clone https://gitee.com/wang_atao/mysql-a_custom_database.git * cd mysql-a_custom_database * make * ./mysql.exe ## 3.Attention * you can only run following commands in mysql.exe: \ is the database's name > create database name; > use database name; > drop database name; \ is the tabel's name > create table name(a int, b double, c char(10),...); > drop table name; > insert into name calues(a,b,c,...); > select * from name; \ <==> exit > quit * there are only one kind of string: * "abc"-------------------√ * 'abc'--------------------× * all commands are case insensitive but database's name and table's name * you can run following commands to quickly use mysql (some data had been stored) * show database; * use database XJGL; * show table; * select * from STUDENT; * insert into STUDENT values("name",0,18); * create table test(a int, b double, c char(20)); * drop table test; * drop database XJGL; ## 4.Expectation * complete the select commands which include conditional statement * add delete, update commands