Which type of database constraint does the following trigger implement? a.Key constraint b.Dynamic integrity constraint c.Static integrity constraint d.Inter-relational integrity constraint
Q: We have database (company) that includes two tables: 1. Department (DeptNo, Dname, location). 2.…
A: PHP (Hypertext Pre-processor) is known as the standard target language that can be used to develop…
Q: What happens if a user tries to add data to a database and does so in a way that causes a record to…
A: Answer is given below .
Q: Which of the following data dictionary objects should be used to view information about the…
A: Data Dictionary: A data dictionary is an essential part of database. It is defined as the…
Q: Which of the following can contain partial or transitive dependencies but has no repeating groups?…
A: Actually, database is a used to stores the data/information.
Q: in sql If you have not yet used the COMMIT command to store the changes permanently in the…
A: Answer: a. True
Q: The Developers team also wants you to ensure that emails are converted to lowercase after an update…
A: A collected information or structured data in the form of table that are stored electronically which…
Q: |1. which one(s) of the following change(s) the name of a database? a) sp_rename d) alter name c)…
A: (Q1)a and cit changes the namer of the database. (Q2) A,B&D these are the attributes which are…
Q: Using MongoDb do the following activities Create database named First. Create a collection named…
A: 1. use First 2. db.createCollection("dbase6211")
Q: What does the %TYPE attribute instruct the system to do? Answers: a, retrieve the database column…
A: The %TYPE attribute instruct the system to do
Q: Consider the following PL/SQL script: SET SERVEROUTPUT ON BEGIN INSERT INTO COURSE…
A: Answer is given below .
Q: Make an Application called “ Student Management System ” that connect with database called…
A: BEGIN TRANSACTION;/* Create a student table */CREATE TABLE student(Id integer PRIMARY KEY, Name…
Q: Build Windows forms for that database tables(Separate Parent and Child forms) Do the insert data…
A: In below we make a code in which we insert the data in database table. here two forms in we insert…
Q: 65. _________ dump schemes have been developed that allow transactions to be active while the dump…
A: Given that, 65. _________ dump schemes have been developed that allow transactions to be active…
Q: the LIKE operator to match exactly one character, which one(s) of the following symbols should be…
A: The answer with correct options is given in step 2.
Q: In SQL, which command(s) is(are) used to enable/disable a database trigger? A MODIFY USER B CHANGE…
A: We need to find the correct option for the given statement. The statement given in the question is -…
Q: create a database called : login inside this database create table called:users defined as…
A: HI THEREI AM ADDING QUERY BELOW TO CREATE USER TABLE AS PER ABOVE REQUIREMENT PLEASE GO THROUGH IT…
Q: Assume you have StudentsDB database stored in MYSQL server that contains the following 2 tables as…
A: 1. Displaying file upload form to upload multiple imagesusing form multipart attribute in the form…
Q: Which of the following statements is true?a. A gap can appear in a sequence created with the NOCACHE…
A: True statement USER_SEQUENCE query verifies the setting for a sequence option. It is used to…
Q: Q 4: Suppose we have the following student table in database. You have to write: • Form load event…
A: Answer :
Q: Which of the following is a transaction isolation level as specified by SQL standard? a.…
A: Given that, 73. Which of the following is a transaction isolation level as specified by SQL…
Q: 107. On a relational database, the kind of constraint which must be specified and does not contain…
A: please see the next step for solution
Q: Oracle Database with code and output on update,delete and insert code of trigger i need it on…
A: Here , CUSTOMERS table we had created : Select * from customers;…
Q: connect with database called university , the database contain 3 Tables o Student Table \ this…
A: STUDENT TABLE BEGIN TRANSACTION;/* Create a student table */CREATE TABLE student(Id integer PRIMARY…
Q: 1. which one(s) of the following change(s) the name of a database? a) sp_rename b) sp_renamedb c)…
A: Note as per our guidelines we are supposed to answer?️ only one question. Kindly repost other…
Q: rite a script that creates a stored procedure named sp_dep4207. When the stored procedure is…
A: Given Procedure name: sp_dep4207 This procedure has to return all rows in the Faculty table for…
Q: Q7:- Choose the correct statement:- Prints the database_information connection = getDbConnection()…
A: Note: In the question, the numbering given for the statement is wrong. The same number “1” is given…
Q: Which of the following operation will not be allowed on the following table if it is stored in a…
A: I have answered the question in step 2.
Q: 1a.Using SQL Terminal window write a query to display the names, block size of Control Files of your…
A: The following question involved usage of sql statements to determine the parameters given in the…
Q: In a relational database, a select operation is used to minimise the size of a table by eliminating…
A: The answer is
Q: Create a database trigger for the following situations: update the…
A: A block of SQL or PL/SQL code that is automatically triggered, by the DBMS when some specific data…
Q: 1.- All products(items) in the shop catalog; product code, name and price 2.- Products sold in the…
A: 1) All products(items) in the shop catalog; product code, name, and price- select code as 'Product…
Q: 1. Display all customers whose email is null or ends with 'fiu.edu’ 2. Display the number of orders…
A: Use LIKE to match the ending of email USE IS NULL to check whether value is null or not SELECT *…
Q: ) Create a trigger so that when user tries to update category table, new value won't take effect…
A: A) DECLARECursor c1 is select table_name from user_tables; BEGINOPEN c1;FETCH c1 INTO tables c1…
Q: 19. Which of the followings could be defined as a field in a database?. A. Muhammad Adib Najmi B. SP…
A: BELOW i have answered:
Q: EF Core API will create which table for the following context? In other words, what would be the…
A: Below is the answer with explanation:
Q: Which of the following statements assigns the role CUSTOMERREP as the default role for Maurice Cain?…
A: The correct statement to assign the role CUSTOMERREP as the default role for Maurice Cain is as…
Q: Restore or run script the Laboratory database that consists of three tables. ThiResult тЫРatient…
A: create three tables as follows TblResult TblPatient TblTest
Q: Database question 2.You created a new user on the database by executing the following command:…
A: Question 2. You created a new user on the database by executing the following command: SQL>…
Q: The database should contain the following six tables:
A: Solution:
Q: 1. If a user has only read authorization for the database, can he modify the data in the database?…
A: Authorisation is a privilege provided by the Database Administer. Different restrctions/privileges…
Q: For each of the following statements, circle T (True) or F (False)
A: Defined the given statement true or false
Q: c) Suppose you want to move from one tablespace to another tablespace. How can you automatically…
A: In database recovery undo records are used to undo any uncommitted changes applied from the redo log…
Q: 1. CourseId ---- String 2. CourseName ---- String 3. TeacherName ---- String 4. college ---- String…
A: · Make an Application called “ Student Management System ” that connect with database called…
Q: EF Core API will create which table for the following context? In other words, what would be the…
A: Entity Framework Core API main use is to create the database schema. Entity Framework Core API…
Q: me Data type Constraint AuthorID Integer, auto-increment Primary key Name Up to 40 characters…
A: Use phpmyadmin to create a MySQL database called “library” that contains the following tables:…
Q: Exercise 5.9 Discuss the strengths and weaknesses of the trigger mechanism. Con trast triggers with…
A: The trigger is a procedure that is automatically invoked in response to a specified change to the…
Q: Open MS Access, create a database named “orderManagement” and perform the following task: - Create a…
A: Steps to create database: Open Access. select File > New. Select Blank database, or select a…
SQL
SQL stands for Structured Query Language, is a form of communication that uses queries structured in a specific format to store, manage & retrieve data from a relational database.
Queries
A query is a type of computer programming language that is used to retrieve data from a database. Databases are useful in a variety of ways. They enable the retrieval of records or parts of records, as well as the performance of various calculations prior to displaying the results. A search query is one type of query that many people perform several times per day. A search query is executed every time you use a search engine to find something. When you press the Enter key, the keywords are sent to the search engine, where they are processed by an algorithm that retrieves related results from the search index. Your query's results are displayed on a search engine results page, or SER.
Which type of
Step by step
Solved in 2 steps
- The Driver Relationship team realized that maintaining driver IDs is difficult and requested an automatic way of incrementing the value when a new driver is added. You need to make the changes on the table to automatically increment the Driver ID. After the change, you need to insert the following driver: First Name: Nursin Last Name: Yilmaz Driving License ID: 4141447 Start Date: 2019-12-28 Driving License Checked: True Rating: 4.0 THIS IS IN SQL FORMAT FOR CENGAGE MINDTAP, PLEASE HELP I AM STUCKplz quickly ?????????????? /*Inserting into patient table*/ INSERT INTO patientVALUES ('1234','Kim Minji','06-05-1994','0557375017'); INSERT INTO patientVALUES ('1334','Han Sohee','06-07-1996','0567374017'); INSERT INTO patientVALUES ('1434','Jeon soyeon','07-10-1998','0537372017'); INSERT INTO patientVALUES ('1646','Lee Taemin','18-06-1993','0501346257'); INSERT INTO patientVALUES ('1645','Yu jimin','11-09-2000','0501846257'); select*from patient; /*Inserting into Doctor table*/INSERT INTO DOCTOR VALUES(2000432, 'khaled' , '05-12-1994' , 0556677880,'Dermatologists'); INSERT INTO DOCTOR VALUES(2000509, 'Ali' , '09-01-2000' , 0559918100, 'Dentistry'); INSERT INTO DOCTOR VALUES(2000389, 'Lewis' ,'21-01-1996' , 0559910000,'Family Physicians'); INSERT INTO DOCTOR VALUES(2000504, 'Saleh' ,'16-06-1998' , 055611500,'Family Physicians'); INSERT INTO DOCTOR VALUES(2000235, 'sara' ,'22-06-1998', 0557745500,'Orthopedics'); select *from doctor; /*Inserting into appointment table*/ INSERT INTO…The database has three tables for tracking horse-riding lessons: Horse with columns: ID - primary key RegisteredName Breed Height BirthDate Student with columns: ID - primary key FirstName LastName Street City State Zip Phone EmailAddress LessonSchedule with columns: HorseID - partial primary key, foreign key references Horse(ID) StudentID - foreign key references Student(ID) LessonDateTime - partial primary key Write a SELECT statement to create a lesson schedule with the lesson date/time, horse ID, and the student's first and last names. Order the results in ascending order by lesson date/time, then by horse ID. Unassigned lesson times (student ID is NULL) should not appear in the schedule. Hint: Perform a join on the Student and LessonSchedule tables, matching the student IDs
- The database has three tables for tracking horse-riding lessons: Horse with columns: ID - primary key RegisteredName Breed Height BirthDate Student with columns: ID - primary key FirstName LastName Street City State Zip Phone EmailAddress LessonSchedule with columns: HorseID - partial primary key, foreign key references Horse(ID) StudentID - foreign key references Student(ID) LessonDateTime - partial primary key Write a SELECT statement to create a lesson schedule with the lesson date/time, horse ID, and the student's first and last names. Order the results in ascending order by lesson date/time, then by horse ID. Unassigned lesson times (student ID is NULL) should not appear in the schedule.Access Assignment Problem: JMS TechWizards is a local company that provides technical services to several small businesses in the area. The company currently keeps its technicians and clients’ records on papers. The manager requests you to create a database to store the technician and clients’ information. The following table contains the clients’ information. Client Number Client Name Street City State Postal Code Telephone Number Billed Paid Technician Number AM53 Ashton-Mills 216 Rivard Anderson TX 78077 512-555-4070 $315.50 $255.00 22 AR76 The Artshop 722 Fisher Liberty Corner TX 78080 254-555-0200 $535.00 $565.00 23 BE29 Bert's Supply 5752 Maumee Liberty Corner TX 78080 254-555-2024 $229.50 $0.00 23 DE76 D & E Grocery 464 Linnell Anderson TX 78077 512-555-6050 $485.70…The Driver Relationship team realized that maintaining driver IDs is difficult and requested an automatic way of incrementing the value when a new driver is added. You need to make the changes on the table to automatically increment the Driver ID. After the change, you need to insert the following driver: First Name: Nursin Last Name: Yilmaz Driving License ID: 4141447 Start Date: 2019-12-28 Driving License Checked: True Rating: 4.0
- calculate_new_balance Given a starting balance (a number), and a list of transaction tuples, calculate the final balance for an account. Transaction tuples are of the shape ("description", amount, "withdrawal") , or ("description", amount, "deposit"). The last entry in the tuple will be either "withdrawal" or "deposit". Every withdrawal decreases the balance of the account by the specified amount, and every deposit increases the balance. The return value is the new account balance, as a number. (which could be negative) Sample calls should look like: >>> calculate_new_balance(100, [("payday", 20, "deposit"), ("new shoes", 50, "withdrawal"), ("illicit winnings", 200, "deposit")])270>>> calculate_new_balance(100, [])100Task 2: The Car Maintenance team also wants to store the actual maintenance operations in the database. The team wants to start with a table to store CAR_ID (CHAR(5)), MAINTENANCE_TYPE_ID (CHAR(5)) and MAINTENANCE_DUE (DATE) date for the operation. Create a new table named MAINTENANCES. The PRIMARY_KEY should be the combination of the three fields. The CAR_ID and MAINTENACNE_TYPE_ID should be foreign keys to their original tables. Cascade update and cascade delete the foreign keys. Answer in MYSQL pleaseAssignment Two: We will write three procedures on our tables, the first of which I have provided as an example. proclnsertPlayer takes one IN VARCHAR(16) paramater and returns an error code in the second SMALLINT (INOUT) parameter. The procedure checks the parameter and, if there are no errors, inserts the value into tblPlayers. Documentation of errors Condition Error code No errors 1st param Null or zero len playerID taken 1 proclnsertGame will receive two IN VARCHAR(16) interpreted as
- DROP TABLE IF EXISTS Worker; CREATE TABLE Worker ( ); 0 INSERT ); WORKER_ID INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT, FIRST NAME TEXT, LAST NAME TEXT, SALARY INTEGER (15), JOINING DATE DATETIME, DEPARTMENT CHAR (25) INTO Worker (WORKER_ID, FIRST_NAME, LAST_NAME, SALARY, JOINING_DATE, DEPARTMENT) VALUES 'Arora', 100000, '14-02-20 09.00.00', 'HR'), (001, 'Monika', (002, 'Niharika', 'Verma' 80000, '14-06-11 09.00.00', 'Admin'), 'HR'), 'Admin'), Admin'), 'Account'), 'Kumar', 75000, '14-01-20 09.00.00', 'Account') DROP TABLE IF EXISTS Bonus; CREATE TABLE Bonus ( ); (003, 'Vishal' 'Singhal', 300000, '14-02-20 09.00.00', (004, 'Amitabh 'Singh', 500000, '14-02-20 09.00.00', (005, 'Vivek' 'Bhati', 500000, '14-06-11 09.00.00'. (006, 'Vipul', 'Diwan' 200000, '14-06-11 09.00.00', (007, 'Satish' (008, 'Geetika', 'Chauhan', 90000, '14-04-11 09.00.00', 'Admin'); WORKER_REF_ID INTEGER, BONUS AMOUNT INTEGER(10), BONUS_DATE DATETIME, FOREIGN KEY (WORKER_REF_ID) REFERENCES Worker (WORKER_ID) ON DELETE…//stored procedure create or replace procedure firstthree (my_seqid in varchar2) as cursor c1 is select sname, grade from student s join taken t on s.sid=t.sid where seqid=my_seqid order by grade desc; -- my_sname varchar2(40); my_sname student.sname%TYPE; -- my_grade number(2,1); my_grade taken.grade%TYPE; begin /* clear the my_tmp table */ delete from my_tmp; commit; open c1; for i in 1..3 loop fetch c1 into my_sname, my_grade; exit when c1%notfound; /* in case the number requested */ /* is more than the total */ /* number of enrolled students */ /* display the result */ dbms_output.put_line('name: ' || my_sname || ' ' || 'grade: ' || my_grade); /* put into temporary table */ insert into my_tmp values(my_sname, my_grade); commit; end loop; close c1; end; / -------------- //php <? $connection = oci_connect ("test", "test", "test"); if ($connection == false){ $e = oci_error();…9. Write a trigger that prohibits duplicate values except for nulls in the NoDupName column of the following table: CREATE TABLE TestUniqueNulls (RowID NoDupName varchar(20) int IDENTITY NOT NULL, NULL); (Note that you can’t do this by using a unique constraint because the constraint wouldn’t allow duplicate null values.) If an INSERT or UPDATE statement creates a duplicate value, roll back the statement and return an error message. Write a series of INSERT statements that tests that duplicate null values are allowed but duplicates of other values are not.