Hi I need some major help with this for my e commerce programming class. In my p
ID: 3803686 • Letter: H
Question
Hi I need some major help with this for my e commerce programming class. In my proposal we are designing a payroll management system. For the design it's just going to work basic functions for salary sheets and having payroll for the normal employer to employee payroll. All I have is the proposal explaining what I was looking forward to designing the assignment, directions are shown below. But as for the tables and columns it will include the example the instructor has given for one table but including all I would need for the design as the employee, employer, payroll and so forth. I am not too sure how to do this and need some help because the final project is to have a fully functioning design so I need some help getting started. Thank you! As said before directions are shown below:In this assignment, create all the tables that you planned in your project proposal including all columns for the tables. When creating the tables pay attention to:
Definition of the columns Definition of the primary and foreign keys, and the use of these two columns to establish relationships (one-to-one, one-to-many, many-to-many) between the tables Setting auto increment, not null, and unsigned attributes for the columns as needed After creating the tables with the columns, you may want to display the tables to make sure that all tables proposed in the proposal are created. If you forget to add a column into a table, need to drop a column, need to rename a column, modify primary keys, rename the table, or modify the definitions of a column, you may do so by using the ALTER command. Use the DESCRIBE command to see the structure of the tables you created in order to make sure that they are created as planned.
For this assignment, you need to send me the SQL queries that you used to create the tables including their columns. If you recorded your SQL queries to create the tables with their columns, just send those to me. The format of the file, where you have the SQL queries, could be .sql, .doc, .docx, or an extension that I can open up with a text editor. If you did not record the SQL queries used to create the tables with their columns, you may run "show create table table_name" SQL syntax to get the SQL syntax that was run in order to create the table_name table. You may then copy the displayed SQL syntax for table_name table, and paste into a text editor (Notepad++, Windows Word, etc.). Below is an example SQL query that was used to create "faculty" table:
CREATE TABLE `faculty` (
`faculty_id` smallint(5) unsigned NOT NULL AUTO_INCREMENT,
`first_name` varchar(20) DEFAULT NULL,
`last_name` varchar(20) NOT NULL,
`email` varchar(30) NOT NULL,
`phone` char(15) DEFAULT NULL,
`password` char(40) NOT NULL,
`user_id` varchar(20) NOT NULL,
`office` varchar(40) NOT NULL,
PRIMARY KEY (`faculty_id`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1
Rember the above SQL query is just for one table. You will have to send the SQL for all tables in the database. Hi I need some major help with this for my e commerce programming class. In my proposal we are designing a payroll management system. For the design it's just going to work basic functions for salary sheets and having payroll for the normal employer to employee payroll. All I have is the proposal explaining what I was looking forward to designing the assignment, directions are shown below. But as for the tables and columns it will include the example the instructor has given for one table but including all I would need for the design as the employee, employer, payroll and so forth. I am not too sure how to do this and need some help because the final project is to have a fully functioning design so I need some help getting started. Thank you! As said before directions are shown below:
In this assignment, create all the tables that you planned in your project proposal including all columns for the tables. When creating the tables pay attention to:
Definition of the columns Definition of the primary and foreign keys, and the use of these two columns to establish relationships (one-to-one, one-to-many, many-to-many) between the tables Setting auto increment, not null, and unsigned attributes for the columns as needed After creating the tables with the columns, you may want to display the tables to make sure that all tables proposed in the proposal are created. If you forget to add a column into a table, need to drop a column, need to rename a column, modify primary keys, rename the table, or modify the definitions of a column, you may do so by using the ALTER command. Use the DESCRIBE command to see the structure of the tables you created in order to make sure that they are created as planned.
For this assignment, you need to send me the SQL queries that you used to create the tables including their columns. If you recorded your SQL queries to create the tables with their columns, just send those to me. The format of the file, where you have the SQL queries, could be .sql, .doc, .docx, or an extension that I can open up with a text editor. If you did not record the SQL queries used to create the tables with their columns, you may run "show create table table_name" SQL syntax to get the SQL syntax that was run in order to create the table_name table. You may then copy the displayed SQL syntax for table_name table, and paste into a text editor (Notepad++, Windows Word, etc.). Below is an example SQL query that was used to create "faculty" table:
CREATE TABLE `faculty` (
`faculty_id` smallint(5) unsigned NOT NULL AUTO_INCREMENT,
`first_name` varchar(20) DEFAULT NULL,
`last_name` varchar(20) NOT NULL,
`email` varchar(30) NOT NULL,
`phone` char(15) DEFAULT NULL,
`password` char(40) NOT NULL,
`user_id` varchar(20) NOT NULL,
`office` varchar(40) NOT NULL,
PRIMARY KEY (`faculty_id`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1
Rember the above SQL query is just for one table. You will have to send the SQL for all tables in the database. Hi I need some major help with this for my e commerce programming class. In my proposal we are designing a payroll management system. For the design it's just going to work basic functions for salary sheets and having payroll for the normal employer to employee payroll. All I have is the proposal explaining what I was looking forward to designing the assignment, directions are shown below. But as for the tables and columns it will include the example the instructor has given for one table but including all I would need for the design as the employee, employer, payroll and so forth. I am not too sure how to do this and need some help because the final project is to have a fully functioning design so I need some help getting started. Thank you! As said before directions are shown below:
In this assignment, create all the tables that you planned in your project proposal including all columns for the tables. When creating the tables pay attention to:
Definition of the columns Definition of the primary and foreign keys, and the use of these two columns to establish relationships (one-to-one, one-to-many, many-to-many) between the tables Setting auto increment, not null, and unsigned attributes for the columns as needed After creating the tables with the columns, you may want to display the tables to make sure that all tables proposed in the proposal are created. If you forget to add a column into a table, need to drop a column, need to rename a column, modify primary keys, rename the table, or modify the definitions of a column, you may do so by using the ALTER command. Use the DESCRIBE command to see the structure of the tables you created in order to make sure that they are created as planned.
For this assignment, you need to send me the SQL queries that you used to create the tables including their columns. If you recorded your SQL queries to create the tables with their columns, just send those to me. The format of the file, where you have the SQL queries, could be .sql, .doc, .docx, or an extension that I can open up with a text editor. If you did not record the SQL queries used to create the tables with their columns, you may run "show create table table_name" SQL syntax to get the SQL syntax that was run in order to create the table_name table. You may then copy the displayed SQL syntax for table_name table, and paste into a text editor (Notepad++, Windows Word, etc.). Below is an example SQL query that was used to create "faculty" table:
CREATE TABLE `faculty` (
`faculty_id` smallint(5) unsigned NOT NULL AUTO_INCREMENT,
`first_name` varchar(20) DEFAULT NULL,
`last_name` varchar(20) NOT NULL,
`email` varchar(30) NOT NULL,
`phone` char(15) DEFAULT NULL,
`password` char(40) NOT NULL,
`user_id` varchar(20) NOT NULL,
`office` varchar(40) NOT NULL,
PRIMARY KEY (`faculty_id`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1
Rember the above SQL query is just for one table. You will have to send the SQL for all tables in the database.
Explanation / Answer
For this payroll managment system we need to record employee, employer, leave, account, and loan information in the database.
Below are the sql queries to ceate tables in the database.
1. CREATE TABLE EMPLOYEE(EID NUMBER(5) PRIMARY KEYENAME VARCHAR2(10),GENDER CHAR(3),HIREDATE DATE,DOB DATE,SALARY NUMBER(5),DESIGNATION VARCHAR2(10));
2. CREATE TABLE EMPLOYER (ENAME VARCHAR2(10) , BUSINESS_AREA VARCHAR2(10), LICENCE_NO NUMBER(5) UNIQUE, BRANCHES NUMBER(5), EID NUMBER(5), FOREIGN KEY(EID) REFERENCES EMPLOYEE(EID));
3. CREATE TABLE LEAVES(EID NUMBER(5) UNIQUE,LTYPE VARCHAR2(10),NO_DAYS_TAKEN NUMBER(3), FOREIGN KEY(EID) REFERENCES EMPLOYEE(EID));
4. CREATE TABLE ACCOUNT(EID NUMBER(5), ACCOUNT_NUMBER NUMBER(15) UNIQUE,BANK VARCHAR2(10),BRANCH VARCHAR2(10), FOREIGN KEY(EID) REFERENCES EMPLOYEE(EID));
5. CREATE TABLE LOAN(EID NUMBER(5), LOAN_TYPE VARCHAR2(10),LOAN_NUMBER(5) UNIQUE,LOAN_AMOUNT NUMBER(10),LOAN_DURATION NUMBER(3),INTEREST NUMBER(3));
Here in this database the employer is the table which records the employer information like business area and and the employees who assigned to that business area.
Employee table stores the employee detailed information like name,age,gender,hiredate etc.
Leave table stored the information about the leaves taken by employees so that accrodingly the employer will credit the salaries to employees.
Account table stores the information about the bank account information of the employees.
Loan table stores the information about the loan taken by the employee if any and accroding to the interest rate and duration the salary will be deducted.