Question

Write an SQL statement to develop a new database called ACCOUNT with the following attributes: 1)...

Write an SQL statement to develop a new database called ACCOUNT with the following attributes: 1) Account_Number, 2) Customer_ID, 3) Account_Type, 4) Balance and 5) Opening_date. Note that you need to determine data types for the attributes.

0 0
Add a comment Improve this question Transcribed image text
Answer #1

SOL Statement:

CREATE TABLE ACCOUNT(
    ACCOUNT_NUMBER NUMBER(11,0) NOT NULL,
    CUSTOMER_ID NUMBER(11,0),
    ACCOUNT_TYPE VARCHAR2(20),
    BALANCE NUMBER(11,0),
    OPENING_DATE DATE DEFAULT SYSDATE
)

Note: Please comment below if you have any doubts

Please up vote the solution if it helped. Thanks!

Add a comment
Know the answer?
Add Answer to:
Write an SQL statement to develop a new database called ACCOUNT with the following attributes: 1)...
Your Answer:

Post as a guest

Your Name:

What's your source?

Earn Coins

Coins can be redeemed for fabulous gifts.

Not the answer you're looking for? Ask your own homework help question. Our experts will answer your question WITHIN MINUTES for Free.
Similar Homework Help Questions
  • Write SQL statements to answer the following questions using Assignment 3’s schema (tables from part 1)....

    Write SQL statements to answer the following questions using Assignment 3’s schema (tables from part 1). 1- Find how many branches had have loans over $2000.00. 2- For each branch, find the most expensive loan. Your output should include Branch Id, loan amount for the highest loan for that Branch. 3- Find how many accounts there are for each customer. The output should include customer id and number of accounts for that customer. 4- Find the total balance amount of...

  • Complete the following tasks using your AP Database. Please submit 1 .doc file of your SQL...

    Complete the following tasks using your AP Database. Please submit 1 .doc file of your SQL statements and a screen shot of a result set showing the data you inserted, updated, or deleted. I want to change the data in the AP database according to the following requirements. 1. I need an additional payment term for Net due 120 days. 2. I need to delete the Vendor Jobtrak because it has never had an invoice. 3. The vendor Coffee Break...

  • Consider the following database and answer the questions below. a) Write the SQL statement the displays...

    Consider the following database and answer the questions below. a) Write the SQL statement the displays the names of the students who have enrolled in the Database Systems course b) Write the SQL statement that displays a list of the students whose names start with 'S' c) Write the SQL statement that displays the Student ID, Student Name, Course ID, and Grade for students that passed at least one course with a grade better than B+ (i.e. A-, A, and...

  • [IN SQL] New to working in SQL and I need to make a database called HAFH....

    [IN SQL] New to working in SQL and I need to make a database called HAFH. I am trying to create tables for the database with the information from the photo above but having issues. I am looking for the syntax that successfully creates these tables, and references each other. I know each table has to be made in a specific order, and that is what I am struggling with. INSPECTOR InsID InsName INSPECTING InsID (FK) BuildingID (FK) Date Last...

  • Write an SQL CREATE statement to create the structure of a table to store the following...

    Write an SQL CREATE statement to create the structure of a table to store the following employee information empLastName, empFirstName, Dept (foreign key to department table), emp Address, empZip, empCity, empState. Use appropriate data types to reflect the data which will be stored in each attribute. Identify attributes which should not be null by using the correct SQL statements in the create statement

  • database and sql problme THE QUESTIONS 3, 4,5 and 6 REFER TO THE RELATIONAL TABLES LISTED...

    database and sql problme THE QUESTIONS 3, 4,5 and 6 REFER TO THE RELATIONAL TABLES LISTED BELOW CREATE TABLE Department ( DECIMAL(5) VARCHAR(30) CHAR(5) DATE NOT NULL NOT NULL NOT NULL * Department number /*Department name * Department manager number */ /Manager start date DNumber DName Manager MSDate CONSTRAINT Department_PK PRIMARY KEY(DNumber) CONSTRAINT Department_CK UNIQUE(DName) CREATE TABLE DeptLocation DECIMAL(5) VARCHAR(50) NOT NULL NOT NULL DNumber * Department number */ * Department location */ Address CONSTRAINT DeptLocation_PK PRIMARY KEY(DNumber, Address) CONSTRAINT...

  • You will need to refer to the University database to answer this question. Write SQL queries...

    You will need to refer to the University database to answer this question. Write SQL queries to perform the following operations. each case show the SQL statement you used and the output from MySQL. You are required to include screenshots showing the actu output of your queries. The tables of University database are as follows: region (region_number, address, telephone, email _address) staff (staff number, name, address, email_address, telephone,

  • Q1. Based on the two tables and the attributes below, write SQL commands for each question...

    Q1. Based on the two tables and the attributes below, write SQL commands for each question to retrieve the data from the database. tbiSales tbiCustomer Customeriumber InvoiceDate Customeriumbere SalesorderNumber CustomerCity CustomerDipCode CustomerTelephone CustomerCreditLima Write the SQL for the following quiries a. List customers who live in New York State. b. List customers with credit limits greater than $50,000. Q2. Draw the relationship with indication of multiplicity between sales class and cash receipt class satisfying the following rules (draw two boxes...

  • A Pages entity in a relational database for tracking web browsing has the following attributes: PageID (the primary key, an integer number, required), PageURL (text, maximum 255 characters, required),...

    A Pages entity in a relational database for tracking web browsing has the following attributes: PageID (the primary key, an integer number, required), PageURL (text, maximum 255 characters, required), IPAddress (text, maximum 15 characters, required), ViewDateTime (date and time the page was viewed, required). (a) Write an SQL Data Definition Language command to create the table for this entity. (b) Write an SQL Data Definition Language command to add a column for a new attribute to this table: ViewDuration (duration...

  • Q.5] Answer the following questions based on the company database (based on the homework assignment 2) y dat...

    Q.5] Answer the following questions based on the company database (based on the homework assignment 2) y database (based on the homework assignment 2) 3 IPage 1. For each department whose average employee salary is more than $30,000, write a SQL statement to retrieve the department name and the number of employees working for that department 2. Write a SQL statement to retrieve first name, last name, and address of each employee who lives in Houston, TX. 3. Write a...

ADVERTISEMENT
Free Homework Help App
Download From Google Play
Scan Your Homework
to Get Instant Free Answers
Need Online Homework Help?
Ask a Question
Get Answers For Free
Most questions answered within 3 hours.
ADVERTISEMENT
ADVERTISEMENT
ADVERTISEMENT