1. Let X represents the number of cars sold each day by a car salesman. The probability distribution
of X is as follows:
a. What is the probability that the salesman will sell more than one car on any one day?
His sales on a
Size (MB) Time (sec) Year
Love Me Do
From Me To You 1.821249
She Loves You 2.202839
I Want To Hold 2.260592
Can't Buy Me Lo 2.05651
A Hard Day's Nig 2.389914
I Feel Fine
Eight Days A We 2.556793
Handout Chapter 6, and 7
1. The stationary store wants to estimate that retail value of greeting cards that it has in its
inventory are normally distributed, with mean value of $2.55 and a standard deviation of
$0.44. If a sample of 49 greeting cards were
Handout Chapter 6
1. A commercial refrigerator specification calls for an average temperature of
8 degrees Celsius. You have been asked to conduct a study to estimate the
population mean for a commercial refrigerator. To do this, you have
selected a rando
The marketing manager of a large supermarket chain would like to develop a model for predicting
weekly sales of pet food based on the shelf space. A random sample of 9 stores is selected, with the
Shelf Space | Sales
Handout chapter 3
1. The chocolate House specializes in hand-dipped chocolates for special occasions.
Recently, several long- time customers have complained about the quality of the
chocolate. It seems there are several partially covered chocolates in eac
Handout chapter 7
1. Five experts have tested two brands of coffee; Brand A and Brand B. They have given a rating of
0-100. The table below shows the ratings. The manager of coffee shop believes Brand A tastes
better than Brand B.
1. The Cost of going to the movies has increased over the last few years. A random
sample of six moviegoers was taken. The following data contains prices for two
tickets, a large popcorn, and two soft drinks:
35, 25, 20, 50, 30, 32.
1. A fast-food restaurant monitors its drive-thru service times electronically to
ensure that its speed of service is meeting the companys goals. A sample
of 28 drive-thru times was recently taken and shown here.
They are the synonyms used to simplify and improve query quality.
DISTINCT: DISTINCT keyword to eliminate duplicate records
Syntax: SELECT DISTINCT column1, column2.columnN FROM table_name;
SELECT column1, colum
1. CHARACTER OR TEXT FUNCTIONS:
Character or text functions are used to manipulate text strings. They accept strings or
characters as input and can return both character and number values as output.
Few of the character or text functions ar
Create table emp as select * from scott.emp;
Create table dept as select * from scott.dept;
CREATE OR REPLACE PROCEDURE salX10
(p_empno IN emp.empno%TYPE)
UPDATE emp SET sal=sal*10
CREATE OR REPLACE FUNCTION tax
CS457 Lab Activity-9
1) Using substitution variables
The variable with & in front can be replaced with a value during runtime.
Insert a row in the emp table for the variables empno,ename,hiredate using substitution
2) ER Model:
1)Create tables emp and dept using scott.emp and scott.dept tables(Hint: Use AS)
2)Display the tables emp and dept
Select * from emp;
Select * from dept;
3)Write a query to display departments not located in DALLAS(Hint: Use != operator)
CS457 Lab Activity-10
Constraint: Constraints help maintain data integrity, prevent invalid data entry into
Constraints help maintain data integrity, prevent invalid data entry into tables.
NOT NULL,UNIQUE,Primary Key,Foreign Key,Check
Ex: Age num
To restrict access to certain data. A view can display a selective portion of the
To make complex queries easy; e.g. a simple select from the view, and the view
is based on a complicated query joining multiple tables.
To allow da
Part - I
SQL Interview Questions
Display the dept information from department table.
select * from dept;
Display the details of all employees.
select * from emp;
Display the name and job for all employees.
select ename, job from emp;