Structured query language

Assignment Help Basic Computer Science
Reference no: EM131204534

Structured Query Language

Goal: Use a transaction to add new rows to two tables at the same time. You must add a row into one table first, before the row can be added into the second table.

Using the class example database (SQLFUN), create the required SQL statements to produce the following results:

Add a new food to the L_foods table from a new supplier.Add Fresh Salmon as menu item 11.

  • The supplier_id is CFF.
  • The product_code is SA.
  • The price is $8.25.
  • There is no price_increase value.

Step 1: Add CFF to the L_suppliers table. (The name of this supplier is Cathy's Fresh Fish).

Step 2: In Oracle or mySQL, make these two inserts in a single transaction:

You first need to add the row to the L_suppliers table because I have created a rule that says, "When a new row is added to the L_foods table, the supplier_id must already exist in the L_suppliers table."

Do a rollback after you have inserted both rows and viewed your changes.

Goal: Using SQL, create a new table. Define each of its columns. Include at least one text and one numeric column.

Create a table using SQL:Build a table of your favorite songs. Include the following:

  • A song ID
  • Name of the song
  • The performer

You may include other columns if you wish.

Reference no: EM131204534

Questions Cloud

How do you define classes in css : How do you define classes in css? Please give an example and explain what classes are?
How does the halt command trap : How does the HALT command Trap x25 work when coding in LC-3? Where is the placement, at the front or back?
What is the value of total purchases at the nash equilibrium : What level of expenditure on the public good maximizes the total level of utility?
Detect the syn flooding attacks and port scan attacks : Calculate the metrics you selected - Use the statistical metrics calculated from the training data set to training the statistical model - Use the statistical metrics calculated from the training data set to training the statistical model.
Structured query language : Goal: Use a transaction to add new rows to two tables at the same time. You must add a row into one table first, before the row can be added into the second table.
Why we would choose to place so much emphasis on qsen : Then, choose one of the QSEN competencies (Patient Centered Care, Teamwork and Collaboration, Informatics, Evidence Based Practice, Safety, or Quality Improvement) and one attitude that you think is most important for a student nurse to incorporat..
Professional language and terminology of systems : Your informed commentary and analysis -- simply repeating what your sources say does not constitute an adequate paper. Your ability to apply the professional language and terminology of systems analysis and design correctly and in context; you are e..
Difference between a security plan and a security policy : What is the difference between a security plan and a security policy? How these do relates to each other?
What is javaserver pages : What is JavaServer Pages? Why Use JSP? Advantages of JSP?

Reviews

Write a Review

Basic Computer Science Questions & Answers

  Write the program to implement your algorithm

calculate what your expected outputs should be. 5. Write the program to implement your algorithm. Test your program using your test cases.

  Understanding of package

List the differences between abstract and interface. Give me examples to demonstrate your understanding of package, abstract and interface.

  Draw at least two query trees that can represent each

Draw the initial query tree for each of these queries, and then show how the query tree is optimized by the algorithm outlined in Section 19.7.

  Define the diffie-hellman key exchange

What is the purpose of the algorithm? Be specific.How does it work? Give an example from personal experience or one that you have read about.What would be an appropriate implementation in an organization for the algorithm?

  Wrtie an alter table statement that adds two new check

Wrtie an Alter Table statement that adds two new check constraints to the invoices table of the ap database.

  Write the complete myfnc function to return the value 1

Write the complete myfnc function to return the value 1 if they are equal and return the value 0 if they are not equal.

  Formulate the tautology underlying the rule

For each of the arguments below, formalize them in propositional logic. If the argument is valid identify which inference rule was used, and formulate the tautology underlying the rule. If the argument is invalid, state whether the inverse or conve..

  You should write each functionality

You should write each functionality from 1-7 in separate functions. You should provide a menu to the user as following:For inputs:

  Explain local-state-national resources unintentional injury

Explain the local, state, and national resources that are available for addressing unintentional and intentional injuries in American communities.

  What is the main feature of random access memory

What is the main feature of random access memory?

  Infrastructure vs competitive advantage

In what ways is IS/IT just infrastructure and in what ways is it a competitive advantage? Do you think it matters on how big or small an organization is for it to be a competitive advantage? What other factors with IS/IT works with or against it bein..

  Develop an effective research plan considering context

Develop an effective research plan considering context, research questions, sources, timeline, and larger implications for writing a formal research report

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd