SlideShare a Scribd company logo
BASE DE DATOS DE BANCO
ACTIVIDAD 1
Create Departments table
CREATE TABLE Departments
(
dept_id varchar(10) NOT NULL ,
dept_name varchar(20) NOT NULL
);
CREATE TABLE ProductType
(
product_type_id varchar(10) NOT NULL ,
product_type_name varchar(50) NOT NULL
);
CREATE TABLE Product
(
product_id varchar(10) NOT NULL ,
product_name varchar(50) NOT NULL ,
Product_type_id varchar(10) NOT NULL ,
date_offered datetime NOT NULL,
date_retired datetime NOT NULL
);
CREATE TABLE Account
(
account_id Integer NOT NULL ,
product_id varchar(10) NOT NULL ,
custom_id integer NOT NULL ,
open_date date NOT NULL ,
close_date date NOT NULL ,
last_activity date NOT NULL ,
account_status varchar(10) NULL,
branch_id varchar(10) NOT NULL,
emp_id varchar(10) NOT NULL,
avail_balance float NOT NULL,
pending_balance float NOT NULL
);
CREATE TABLE Customer
(
custom_id integer NOT NULL ,
custom_type char(2) NOT NULL,
fed_id varchar(12) NOT NULL ,
custom_address varchar(30) NULL ,
custom_city varchar(20) NULL ,
custom_state varchar(20) NULL ,
custom_zip varchar(10) NULL
);
CREATE TABLE Business
(
busi_id char(10) NOT NULL ,
custom_id integer NOT NULL ,
busi_name varchar(40) NOT NULL ,
vend_state char(5) NULL ,
incorp_date date NOT NULL
);
CREATE TABLE Officer
(
officer_id varchar(10) NOT NULL ,
custom_id integer NOT NULL ,
first_name varchar(30) NOT NULL ,
last_name varchar(30) NOT NULL ,
starts_date date NOT NULL ,
end_date date NOT NULL
);
CREATE TABLE Individual
(
individual_id char(10) NOT NULL ,
custom_id integer NOT NULL ,
f_name varchar(30) NOT NULL ,
l_name varchar(30) NOT NULL ,
birth_date date NOT NULL
);
CREATE TABLE Transactions
(
txn_id integer NOT NULL ,
txn_date datetime NOT NULL ,
account_id integer NOT NULL ,
txn_cd varchar(10) NOT NULL ,
amount decimal(10,2) NULL ,
emp_id varchar(10) NOT NULL ,
branch_id varchar(10) NOT NULL ,
funds_avail date NOT NULL
);
CREATE TABLE Employee
(
emp_id varchar(10) NOT NULL ,
fname varchar(20) NOT NULL ,
lname varchar(20) NOT NULL ,
s_date date NOT NULL ,
e_date date NOT NULL ,
superior_emp_id varchar(10) NOT NULL ,
dept_id smallint NOT NULL ,
tit varchar(20) NULL,
branch_id smallint NOT NULL
);
CREATE TABLE Branch
(
branch_id varchar(10) NOT NULL,
branch_name varchar(20) NOT NULL ,
branch_address char(30) NULL ,
branch_city char(20) NULL ,
branch_state varchar(20) NULL ,
branch_zip char(12) NULL
);-------------------------
----------------------
-- Define primary keys
----------------------
ALTER TABLE Customer WITH NOCHECK ADD CONSTRAINT PK_Customer PRIMARY KEY
CLUSTERED (custom_id);
ALTER TABLE Branch WITH NOCHECK ADD CONSTRAINT PK_Branch PRIMARY KEY
CLUSTERED (branch_id);
ALTER TABLE Product_type WITH NOCHECK ADD CONSTRAINT PK_Product_type PRIMARY
KEY CLUSTERED (product_type_id);
ALTER TABLE Product WITH NOCHECK ADD CONSTRAINT PK_Product PRIMARY KEY
CLUSTERED (product_id);
ALTER TABLE Account WITH NOCHECK ADD CONSTRAINT PK_Account PRIMARY KEY
CLUSTERED (account_id);
ALTER TABLE Officer WITH NOCHECK ADD CONSTRAINT PK_Officer PRIMARY KEY
CLUSTERED (officer_id);
ALTER TABLE Business WITH NOCHECK ADD CONSTRAINT PK_Business PRIMARY KEY
CLUSTERED (busi_id);
ALTER TABLE Individual WITH NOCHECK ADD CONSTRAINT PK_Individual PRIMARY KEY
CLUSTERED (individual_id);
ALTER TABLE Employee WITH NOCHECK ADD CONSTRAINT PK_Employee PRIMARY KEY
CLUSTERED (emp_id);
ALTER TABLE Transactions WITH NOCHECK ADD CONSTRAINT PK_Transactions PRIMARY
KEY CLUSTERED (txn_id);
ALTER TABLE Deparments WITH NOCHECK ADD CONSTRAINT PK_Departments PRIMARY
KEY CLUSTERED (dept_id);
----------------------
-- Define foreign keys
----------------------
ALTER TABLE Product ADD
CONSTRAINT FK_Product_ProductType FOREIGN KEY (product_type_id) REFERENCES
ProductType (product_type_id);
ALTER TABLE Account ADD
CONSTRAINT FK_Account_Product FOREIGN KEY (product_id) REFERENCES Product
(product_id),
CONSTRAINT FK_Account_Customer FOREIGN KEY (custom_id) REFERENCES Customer
(custom_id),
CONSTRAINT FK_Account_Branch FOREIGN KEY (branch_id) REFERENCES Branch
(branch_id),
CONSTRAINT FK_Account_Employee FOREIGN KEY (emp_id) REFERENCES Employee
(emp_id);
ALTER TABLE Business ADD
CONSTRAINT FK_Business_Customer FOREIGN KEY (custom_id) REFERENCES Customer
(custom_id);
ALTER TABLE Individual ADD
CONSTRAINT FK_Individual_Customer FOREIGN KEY (custom_id) REFERENCES Customer
(custom_id);
ALTER TABLE Officer ADD
CONSTRAINT FK_Officer_Customer FOREIGN KEY (custom_id) REFERENCES Customer
(custom_id);
ALTER TABLE Transactions ADD
CONSTRAINT FK_Transactions_Account FOREIGN KEY (account_id) REFERENCES Account
(account_id),
CONSTRAINT FK_Transactions_Employee FOREIGN KEY (emp_id) REFERENCES Employee
(emp_id),
CONSTRAINT FK_Transactions_Branch FOREIGN KEY (branch_id) REFERENCES Branch
(branch_id);
ALTER TABLE Employee ADD
CONSTRAINT FK_Employee_Departments FOREIGN KEY (dept_id) REFERENCES Deparments
(dept_id),
CONSTRAINT FK_Employee_Employee FOREIGN KEY (superior_emp_id) REFERENCES
Employee (superior_emp_id),
CONSTRAINT FK_Employee_Branch FOREIGN KEY (branch_id) REFERENCES Branch
(branch_id);
CREATE TABLE Departments
(
dept_id smallint NOT NULL ,
dept_name varchar(20) NOT NULL
);
INSERT INTO Departaments(dept_id, dept_name)
VALUES(501, 'sistema')
INSERT INTO Departaments(dept_id, dept_name)
VALUES(502, 'gerencia')
INSERT INTO Departaments(dept_id, dept_name)
VALUES(503, 'contabilidad')
INSERT INTO Departaments(dept_id, dept_name)
VALUES(504, 'administracion')
INSERT INTO Departaments(dept_id, dept_name)
VALUES(505, 'recursos humanos')
INSERT INTO Departaments(dept_id, dept_name)
VALUES(506, 'tramites')
INSERT INTO Departaments(dept_id, dept_name)
VALUES(507, 'atencion a cliente' )
INSERT INTO Departaments(dept_id, dept_name)
VALUES(508, 'cajas' )
INSERT INTO Departaments(dept_id, dept_name)
VALUES(509, 'creditos')
INSERT INTO Departaments(dept_id, dept_name)
VALUES(510, 'hipotecaria')
INSERT INTO Departaments(dept_id, dept_name)
VALUES(511, 'seguridad')
INSERT INTO Departaments(dept_id, dept_name)
VALUES(512, 'limpieza')
INSERT INTO Departaments(dept_id, dept_name)
VALUES(513, 'finanzas')
INSERT INTO Departaments(dept_id, dept_name)
VALUES(514, 'publicidad')
INSERT INTO Departaments(dept_id, dept_name)
VALUES(515, 'juridico')
INSERT INTO Departaments(dept_id, dept_name)
VALUES(516, 'control de calidad')
INSERT INTO Departaments(dept_id, dept_name)
VALUES(517, 'transacciones')
INSERT INTO Departaments(dept_id, dept_name)
VALUES(518, 'cobranzas')
CREATE TABLE Customer
(
custom_id integer NOT NULL ,
custom_type char(2) NOT NULL,
fed_id varchar(12) NOT NULL ,
custom_address varchar(30) NULL ,
custom_city varchar(20) NULL ,
custom_state varchar(20) NULL ,
custom_zip varchar(10) NULL
);
INSERT INTO Customer(custom_id,
custom_type,fed_id,custom_address,custom_city,custom_state,custom_zip)
VALUES('0001', 'ep', '00012341', 'reforma #145', 'mexico', 'veracruz', '95400');
INSERT INTO Customer(custom_id,
custom_type,fed_id,custom_address,custom_city,custom_state,custom_zip)
VALUES('0002', 'pl', '00012342', 'carpio #43', 'mexico', 'guadalajara', '94670');
INSERT INTO Customer(custom_id,
custom_type,fed_id,custom_address,custom_city,custom_state,custom_zip)
VALUES('0003','pr', '00012343', 'libertad #1136', 'mexico', 'xalapa', '45678');
INSERT INTO Customer(custom_id,
custom_type,fed_id,custom_address,custom_city,custom_state,custom_zip)
VALUES('0004', 'hm', '00012344', 'campo real #717', 'mexico', 'monterrey', '45678');
INSERT INTO Customer(custom_id,
custom_type,fed_id,custom_address,custom_city,custom_state,custom_zip)
VALUES('0005', 'pl', '00012345', 'ruiz cortinez #67', 'mexico', 'veracruz', '95400');
INSERT INTO Customer(custom_id,
custom_type,fed_id,custom_address,custom_city,custom_state,custom_zip)
VALUES('0006', 'ep', '00012346', 'diaz miron #654', 'mexico', 'veracruz', '95400');
INSERT INTO Customer(custom_id,
custom_type,fed_id,custom_address,custom_city,custom_state,custom_zip)
VALUES('0007', 'hm', '00012347', '2 de abril #245', 'mexico', 'yucatan', '45673');
INSERT INTO Customer(custom_id,
custom_type,fed_id,custom_address,custom_city,custom_state,custom_zip)
VALUES('0008', 'pr', '00012348', '20 de noviembre #1678', 'mexico', 'guanajuato', '56433');
INSERT INTO Customer(custom_id,
custom_type,fed_id,custom_address,custom_city,custom_state,custom_zip)
VALUES('0009', 'pl', '00012349', 'murillo vidal #25', 'mexico', 'veracruz', '95400');
INSERT INTO Customer(custom_id,
custom_type,fed_id,custom_address,custom_city,custom_state,custom_zip)
VALUES('0010', 'ep', '00012351', 'arriola molina #456', 'mexico', 'xalapa', '45678');
CREATE TABLE Officer
(
officer_id varchar(10) NOT NULL ,
custom_id integer NOT NULL ,
first_name varchar(30) NOT NULL ,
last_name varchar(30) NOT NULL ,
starts_date date NOT NULL ,
end_date date NOT NULL
);
INSERT INTO Officer(officer_id, custom_id, first_name, last_name, starts_date, end_date)
VALUES('1000', '0001', 'roberto', 'meguelle', '2010/08/03', '2010/12/31');
INSERT INTO Officer(officer_id, custom_id, first_name, last_name, starts_date, end_date)
VALUES('2000', '0002', 'juan carlos', 'vidal', '1990/10/23', '1995/05/29');
INSERT INTO Officer(officer_id, custom_id, first_name, last_name, starts_date, end_date)
VALUES('3000', '0003', 'fernando', 'guzman', '2010/01/03', '2010/08/16');
INSERT INTO Officer(officer_id, custom_id, first_name, last_name, starts_date, end_date)
VALUES('4000', '0004', 'enrique', 'rodriguez', '2010/05/07', '2010/07/12');
INSERT INTO Officer(officer_id, custom_id, first_name, last_name, starts_date, end_date)
VALUES('5000', '0005', 'jose', 'mimendi', '2010/02/14', '2010/03/19');
INSERT INTO Officer(officer_id, custom_id, first_name, last_name, starts_date, end_date)
VALUES('6000', '0006', 'ivan', 'nicanor', '2000/09/12', '2003/12/17');
INSERT INTO Officer(officer_id, custom_id, first_name, last_name, starts_date, end_date)
VALUES('7000', '0007', 'jonathan', 'nieto', '2008/05/18', '2010/11/22');
INSERT INTO Officer(officer_id, custom_id, first_name, last_name, starts_date, end_date)
VALUES('8000', '0008', 'julian', 'hernandez', '2003/10/16', '2005/09/11');
INSERT INTO Officer(officer_id, custom_id, first_name, last_name, starts_date, end_date)
VALUES('9000', '0009', 'arturo', 'lopez', '2010/01/03', '2010/12/31');
INSERT INTO Officer(officer_id, custom_id, first_name, last_name, starts_date, end_date)
VALUES('1100', '0010', 'noe', 'avila', '2007/07/25', '2010/11/20');
CREATE TABLE Business
(
busi_id char(10) NOT NULL ,
custom_id integer NOT NULL ,
busi_name varchar(40) NOT NULL ,
vend_state char(5) NULL ,
incorp_date date NOT NULL
);
INSERT INTO Business(busi_id, custom_id, busi_name, vend_state, incorp_date)
VALUES('123451', '0001', 'tramite tarjeta', 'ver', '2010/09/10');
INSERT INTO Business(busi_id, custom_id, busi_name, vend_state, incorp_date)
VALUES('123452', '0002', 'asesoria bancaria', 'gdl', '2003/06/19');
INSERT INTO Business(busi_id, custom_id, busi_name, vend_state, incorp_date)
VALUES('123453', '0003', 'cuenta cheques', 'xlp', '2001/01/22');
INSERT INTO Business(busi_id, custom_id, busi_name, vend_state, incorp_date)
VALUES('123454', '0004', 'tramite tarjeta', 'mty', '2006/01/11');
INSERT INTO Business(busi_id, custom_id, busi_name, vend_state, incorp_date)
VALUES('123455', '0005', 'cancelacion', 'ver', '2006/04/24');
INSERT INTO Business(busi_id, custom_id, busi_name, vend_state, incorp_date)
VALUES('123456', '0006', 'deposito', 'ver', '2010/06/15');
INSERT INTO Business(busi_id, custom_id, busi_name, vend_state, incorp_date)
VALUES('123457', '0007', 'retiro en efectivo', 'mex', '2009/10/24');
INSERT INTO Business(busi_id, custom_id, busi_name, vend_state, incorp_date)
VALUES('123458', '0008', 'tramite de tarjeta', 'ver', '2008/07/09');
INSERT INTO Business(busi_id, custom_id, busi_name, vend_state, incorp_date)
VALUES('123459', '0009', 'deposito', 'gdl', '2010/08/08');
INSERT INTO Business(busi_id, custom_id, busi_name, vend_state, incorp_date)
VALUES('123461', '0010', 'cuenta cheques', 'mex', '2000/09/10');
CREATE TABLE Individual
(
individual_id char(10) NOT NULL ,
custom_id integer NOT NULL ,
f_name varchar(30) NOT NULL ,
l_name varchar(30) NOT NULL ,
birth_date date NOT NULL
);
INSERT INTO Individual(individual_id, custom_id, f_name, l_name, birth_date)
VALUES('10131', '0001', 'monica','lorenzo', '1984/09/11');
INSERT INTO Individual(individual_id, custom_id,f_name, l_name, birth_date)
VALUES('10132', '0002', 'mariana', 'camara', '1986/11/23');
INSERT INTO Individual(individual_id, custom_id, f_name, l_name, birth_date)
VALUES('10133', '0003', 'victor', 'vidal', '1990/03/15');
INSERT INTO Individual(individual_id, custom_id, f_name, l_name, birth_date)
VALUES('10134', '0004', 'manuel', 'hernandez', '1970/07/17');
INSERT INTO Individual(individual_id, custom_id, f_name, l_name, birth_date)
VALUES('10135', '0005', 'gonzalo', 'nicanor', '1978/01/05');
INSERT INTO Individual(individual_id, custom_id, f_name, l_name, birth_date)
VALUES('10136', '0006', 'daniel', 'limon', '1976/02/14');
INSERT INTO Individual(individual_id, custom_id, f_name, l_name, birth_date)
VALUES('10137', '0007', 'lorena', 'perez', '1979/11/11');
INSERT INTO Individual(individual_id, custom_id, f_name, l_name, birth_date)
VALUES('10138', '0008', 'zamara', 'moreno', '1984/03/22');
INSERT INTO Individual(individual_id, custom_id, f_name, l_name, birth_date)
VALUES('10139', '0009', 'saul', 'zamorano', '1989/12/01');
INSERT INTO Individual(individual_id, custom_id, f_name, l_name, birth_date)
VALUES('10140', '0010', 'johnny', 'granda', '1978/07/01');
CREATE TABLE Transactions
(
txn_id integer NOT NULL ,
txn_date datetime NOT NULL ,
account_id integer NOT NULL ,
txn_cd varchar(10) NOT NULL ,
amount decimal(10,2) NULL ,
emp_id varchar(10) NOT NULL ,
branch_id varchar(10) NOT NULL ,
funds_avail date NOT NULL
);
INSERT INTO Transactions
(txn_id,txn_date,account_id,txn_cd,amount,emp_id,branch_id,funds_avail)
VALUES(00001,'2005-02-22',101,'CDT','1000.00',1,901,'2005-02-22');
INSERT INTO
Transactions(txn_id,txn_date,account_id,txn_cd,amount,emp_id,branch_id,funds_avail)
VALUES(00002,'2005-02-23',102,'CDT','525.75',2,902,'2005-02-23');
INSERT INTO Transactions
(txn_id,txn_date,account_id,txn_cd,amount,emp_id,branch_id,funds_avail)
VALUES(00003,'2005-02-24',103,'DBT','100.00',3,903,'2005-02-24');
INSERT INTO Transactions
(txn_id,txn_date,account_id,txn_cd,amount,emp_id,branch_id,funds_avail)
VALUES(00004,'2005-02-24',104,'CDT','55',4,904,'2005-02-25');
INSERT INTO Transactions
(txn_id,txn_date,account_id,txn_cd,amount,emp_id,branch_id,funds_avail)
VALUES(00005,'2005-02-25',105,'DBT','50',5,905,'2005-02-26');
INSERT INTO Transactions
(txn_id,txn_date,account_id,txn_cd,amount,emp_id,branch_id,funds_avail)
VALUES(00007,'2005-02-25',107,'CDT','125.37',6,906,'2005-02-27');
INSERT INTO Transactions
(txn_id,txn_date,account_id,txn_cd,amount,emp_id,branch_id,funds_avail)
VALUES(00008,'2005-02-26',108,'DBT','10',7,907,'2005-02-28');
INSERT INTO Transactions
(txn_id,txn_date,account_id,txn_cd,amount,emp_id,branch_id,funds_avail)
VALUES(00009,'2005-02-27',109,'CDT','75',8,908,'2005-02-29');
CREATE TABLE Account
(
account_id Integer NOT NULL ,
product_id varchar(10) NOT NULL ,
custom_id integer NOT NULL ,
open_date date NOT NULL ,
close_date date NOT NULL ,
last_activity date NOT NULL ,
account_status varchar(10) NULL,
branch_id varchar(10) NOT NULL,
emp_id varchar(10) NOT NULL,
avail_balance float NOT NULL,
pending_balance float NOT NULL
);
INSERT INTO
Account(account_id,product_id,custom_id,open_date,close_date,last_activity,account_status,branc
h_id,emp_id,avail_balance,pending_balance)
VALUES(101,20001,0001,'2005-02-22','2005-03-02','2005-05-11','active',901,1,'1000.00','200');
INSERT INTO
Account(account_id,product_id,custom_id,open_date,close_date,last_activity,account_status,branc
h_id,emp_id,avail_balance,pending_balance)
VALUES(102,20002,0002,'2005-02-23','2005-03-03','2005-05-12','active',902,2,'1000.00','200');
INSERT INTO
Account(account_id,product_id,custom_id,open_date,close_date,last_activity,account_status,branc
h_id,emp_id,avail_balance,pending_balance)
VALUES(103,20003,0003,'2005-02-24','2005-03-04','2005-05-13','active',903,3,'1000.00','200');
INSERT INTO
Account(account_id,product_id,custom_id,open_date,close_date,last_activity,account_status,branc
h_id,emp_id,avail_balance,pending_balance)
VALUES(104,20004,0004,'2005-02-25','2005-03-05','2005-05-14','active',904,4,'1000.00','200');
INSERT INTO
Account(account_id,product_id,custom_id,open_date,close_date,last_activity,account_status,branc
h_id,emp_id,avail_balance,pending_balance)
VALUES(105,20005,0005,'2005-02-26','2005-03-06','2005-05-15','inactive',905,5,'1000.00','200');
INSERT INTO
Account(account_id,product_id,custom_id,open_date,close_date,last_activity,account_status,branc
h_id,emp_id,avail_balance,pending_balance)
VALUES(107,20006,0006,'2005-02-27','2005-04-07','2005-05-15','inactive',906,6,'1000.00','200');
INSERT INTO
Account(account_id,product_id,custom_id,open_date,close_date,last_activity,account_status,branc
h_id,emp_id,avail_balance,pending_balance)
VALUES(108,20007,0007,'2005-02-28','2005-04-08','2005-05-16','inactive',907,7,'1000.00','200');
INSERT INTO
Account(account_id,product_id,custom_id,open_date,close_date,last_activity,account_status,branc
h_id,emp_id,avail_balance,pending_balance)
VALUES(109,20009,0008,'2005-02-29','2005-04-09','2005-05-17','inactive',908,8,'1000.00','200');
CREATE TABLE Employee
(
emp_id varchar(10) NOT NULL ,
fname varchar(20) NOT NULL ,
lname varchar(20) NOT NULL ,
s_date date NOT NULL ,
e_date date NOT NULL ,
superior_emp_id varchar(10) NOT NULL ,
dept_id smallint NOT NULL ,
tit varchar(20) NULL,
branch_id smallint NOT NULL
);
INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id,
dept_id,tit,branch_id)
VALUES(1, 'Michael','Smith','2005-04-03','2008-04-03',801,501,'informatica',901);
INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id,
dept_id,tit,branch_id)
VALUES(2, 'Susan','Barker','2005-04-03','2008-04-03',802,502,'gerente',902);
INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id,
dept_id,tit,branch_id)
VALUES(3, 'Robert','Tyler','2005-04-03','2008-04-03',803,503,'contador',903);
INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id,
dept_id,tit,branch_id)
VALUES(4, 'Susan','Hawthorne','2005-04-03','2008-04-03',805,504,'gerente',904);
INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id,
dept_id,tit,branch_id)
VALUES(5, 'John','Gooding','2005-04-03','2008-04-03',805,505,'acesor',905);
INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id,
dept_id,tit,branch_id)
VALUES(6, 'Helen','Fleming','2005-04-03','2008-04-03',806,506,'acesor de tramites',906);
INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id,
dept_id,tit,branch_id)
VALUES(7, 'Chris','Tucker','2005-04-03','2008-04-03',807,507,'operador',907);
INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id,
dept_id,tit,branch_id)
VALUES(8, 'Sarah','Parker','2005-04-03','2008-04-03',808,508,'cajero',908);
INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id,
dept_id,tit,branch_id)
VALUES(9, 'Jane','Grossman','2005-04-03','2008-04-03',809,509,'ejecutivo',909);
INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id,
dept_id,tit,branch_id)
VALUES(10, 'Paula','Roberts','2005-04-03','2008-04-03',810,510,'abogado',910);
INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id,
dept_id,tit,branch_id)
VALUES(11, 'Thomas','Ziegler','2005-04-03','2008-04-03',811,511,'policia',911);
INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id,
dept_id,tit,branch_id)
VALUES(12, 'Samantha','Jameson','2005-04-03','2008-04-03',812,512,'intendente',913);
INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id,
dept_id,tit,branch_id)
VALUES(13, 'John','Blake','2005-04-03','2008-04-03',813,513,'ejecutivo',914);
INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id,
dept_id,tit,branch_id)
VALUES(14, 'Cindy','Mason','2005-04-03','2008-04-03',814,514,'diseรฑador',915);
INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id,
dept_id,tit,branch_id)
VALUES(15, 'Frank','Portmant','2005-04-03','2008-04-03',815,515,'abogado',915);
INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id,
dept_id,tit,branch_id)
VALUES(16, 'Theresa','Markham','2005-04-03','2008-04-03',816,516,'acesor',916);
INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id,
dept_id,tit,branch_id)
VALUES(17, 'Beth','Fowler','2005-04-03','2008-04-03',817,517,'ejecutivo',917);
INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id,
dept_id,tit,branch_id)
VALUES(18, 'Rick','Tulman','2005-04-03','2008-04-03',818,518,'cobrador',918);
CREATE TABLE ProductType
(
product_type_id varchar(10) NOT NULL ,
product_type_name varchar(50) NOT NULL
);
INSERT INTO ProductType( product_type_id ,product_type_name)
VALUES(601,'credito');
INSERT INTO ProductType( product_type_id ,product_type_name)
VALUES(602,'debito');
INSERT INTO ProductType( product_type_id ,product_type_name)
VALUES(603,'platino');
INSERT INTO ProductType( product_type_id ,product_type_name)
VALUES(604,'dorada');
INSERT INTO ProductType( product_type_id ,product_type_name)
VALUES(605,'empresarial');
INSERT INTO ProductType( product_type_id ,product_type_name)
VALUES(606,'preferente');
INSERT INTO ProductType( product_type_id ,product_type_name)
VALUES(607,'credito');
INSERT INTO ProductType( product_type_id ,product_type_name)
VALUES(608,'debito');
INSERT INTO ProductType( product_type_id ,product_type_name)
VALUES(609,'platino');
INSERT INTO ProductType( product_type_id ,product_type_name)
VALUES(610,'preferente');
INSERT INTO ProductType( product_type_id ,product_type_name)
VALUES(611,'empresarial');
INSERT INTO ProductType( product_type_id ,product_type_name)
VALUES(612,'dorada');
INSERT INTO ProductType( product_type_id ,product_type_name)
VALUES(613,'credito');
INSERT INTO ProductType( product_type_id ,product_type_name)
VALUES(614,'debito');
INSERT INTO ProductType( product_type_id ,product_type_name)
VALUES(615,'empresarial');
INSERT INTO ProductType( product_type_id ,product_type_name)
VALUES(616,'platino');
INSERT INTO ProductType( product_type_id ,product_type_name)
VALUES(617,'dorada');
INSERT INTO ProductType( product_type_id ,product_type_name)
VALUES(618,'credito');
CREATE TABLE Product
(
product_id varchar(10) NOT NULL ,
product_name varchar(50) NOT NULL ,
Product_type_id varchar(10) NOT NULL ,
date_offered datetime NOT NULL,
date_retired datetime NOT NULL
);
INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired)
VALUES(20001,'tarjeta',601,'2005-01-28','2006-01-05');
INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired)
VALUES(20002,'tarjeta',602,'2005-02-28','2006-02-06');
INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired)
VALUES(20003,'tarjeta',603,'2005-03-28','2006-03-07');
INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired)
VALUES(20004,'tarjeta',604,'2005-04-28','2006-04-11');
INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired)
VALUES(20005,'tarjeta',605,'2005-05-28','2006-05-30');
INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired)
VALUES(20006,'tarjeta',606,'2005-06-28','2006-06-24');
INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired)
VALUES(20007,'tarjeta',607,'2005-07-28','2006-07-28');
INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired)
VALUES(20008,'tarjeta',608,'2005-08-28','2006-08-14');
INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired)
VALUES(20009,'tarjeta',609,'2005-09-28','2006-09-16');
INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired)
VALUES(20010,'tarjeta',610,'2005-10-28','2006-10-15');
INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired)
VALUES(20011,'tarjeta',611,'2005-11-28','2006-11-13');
INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired)
VALUES(20012,'tarjeta',612,'2005-12-28','2006-12-29');
INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired)
VALUES(20013,'tarjeta',613,'2005-01-28','2006-02-28');
INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired)
VALUES(20014,'tarjeta',614,'2005-02-28','2006-03-31');
INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired)
VALUES(20015,'tarjeta',615,'2005-03-28','2006-04-19');
INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired)
VALUES(20016,'tarjeta',616,'2005-04-28','2006-05-02');
INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired)
VALUES(20017,'tarjeta',617,'2005-05-28','2006-06-08');
INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired)
VALUES(20018,'tarjeta',618,'2005-06-28','2006-07-12');
CREATE TABLE Branch
(
branch_id varchar(10) NOT NULL,
branch_name varchar(20) NOT NULL ,
branch_address char(30) NULL ,
branch_city char(20) NULL ,
branch_state varchar(20) NULL ,
branch_zip char(12) NULL
);
INSERT INTO Branch( branch_id, branch_name, branch_address,
branch_city,branch_state,branch_zip)
VALUES(901,'diaz miron','diaz miron #655','veracruz','veracruz','91700');
INSERT INTO Branch( branch_id, branch_name, branch_address,
branch_city,branch_state,branch_zip)
VALUES(902,'independencia','independencia #273','veracruz','veracruz','91710' );
INSERT INTO Branch( branch_id, branch_name, branch_address,
branch_city,branch_state,branch_zip)
VALUES(903,'ruiz cortinez','ruiz cortinez #949','veracruz','veracruz','91720');
INSERT INTO Branch( branch_id, branch_name, branch_address,
branch_city,branch_state,branch_zip)
VALUES(904,'2 de abril','2 de abril #399','veracruz','veracruz','91730');
INSERT INTO Branch( branch_id, branch_name, branch_address,
branch_city,branch_state,branch_zip)
VALUES(905,'20 de noviembre','diaz miron #8838','veracruz','veracruz','91740');
INSERT INTO Branch( branch_id, branch_name, branch_address,
branch_city,branch_state,branch_zip)
VALUES(906,'bolivar','bolivar #427','veracruz','veracruz','91750');
INSERT INTO Branch( branch_id, branch_name, branch_address,
branch_city,branch_state,branch_zip)
VALUES(907,'reforma','reforma #345','veracruz','veracruz','91760');
INSERT INTO Branch( branch_id, branch_name, branch_address,
branch_city,branch_state,branch_zip)
VALUES(908,'juan pablo II','juan pablo II #8060','veracruz','veracruz','91770');
INSERT INTO Branch( branch_id, branch_name, branch_address,
branch_city,branch_state,branch_zip)
VALUES(909,'costa verde','costa verde #6780','veracruz','veracruz','91780');
INSERT INTO Branch( branch_id, branch_name, branch_address,
branch_city,branch_state,branch_zip)
VALUES(910,'costa de oro','costa de oro #523','veracruz','veracruz','91790');
INSERT INTO Branch( branch_id, branch_name, branch_address,
branch_city,branch_state,branch_zip)
VALUES(911,'cuauhtemoc','cuauhtemoc #499','veracruz','veracruz','91800');
INSERT INTO Branch( branch_id, branch_name, branch_address,
branch_city,branch_state,branch_zip)
VALUES(912,'miguel aleman','miguel aleman #324','veracruz','veracruz','91810');
INSERT INTO Branch( branch_id, branch_name, branch_address,
branch_city,branch_state,branch_zip)
VALUES(913,'circunvalacion','circunvalacion #7011','veracruz','veracruz','91820');
INSERT INTO Branch( branch_id, branch_name, branch_address,
branch_city,branch_state,branch_zip)
VALUES(914,'la fragua','la fragua #6030','veracruz','veracruz','91830');
INSERT INTO Branch( branch_id, branch_name, branch_address,
branch_city,branch_state,branch_zip)
VALUES(915,'marti','marti #7030','veracruz','veracruz','91840');
INSERT INTO Branch( branch_id, branch_name, branch_address,
branch_city,branch_state,branch_zip)
VALUES(916,'americas','americas #1110','veracruz','veracruz','91850');
INSERT INTO Branch( branch_id, branch_name, branch_address,
branch_city,branch_state,branch_zip)
VALUES(917,'5 de mayo','5 de mayo #220','veracruz','veracruz','91860');
INSERT INTO Branch( branch_id, branch_name, branch_address,
branch_city,branch_state,branch_zip)
VALUES(918,'hidalgo','hidalgo #330','veracruz','veracruz','91870');

More Related Content

What's hot

Actividad 1 de unidad 4
Actividad 1 de unidad 4Actividad 1 de unidad 4
Actividad 1 de unidad 4sergio
ย 
Business News, Personal Finance and Money News
Business News, Personal Finance and Money NewsBusiness News, Personal Finance and Money News
Business News, Personal Finance and Money News
phobicmistake8593
ย 
Milestone 1 FINAL
Milestone 1 FINALMilestone 1 FINAL
Milestone 1 FINALDanny Nguyen
ย 
Business News, Personal Finance and Money News
Business News, Personal Finance and Money NewsBusiness News, Personal Finance and Money News
Business News, Personal Finance and Money News
bernardwilcox8
ย 
Modern JavaScript Engine Performance
Modern JavaScript Engine PerformanceModern JavaScript Engine Performance
Modern JavaScript Engine PerformanceCatalin Dumitru
ย 
Unidad 4 actividad 1
Unidad 4 actividad 1Unidad 4 actividad 1
Unidad 4 actividad 1KARY
ย 
Business News, Personal Finance and Money News
Business News, Personal Finance and Money NewsBusiness News, Personal Finance and Money News
Business News, Personal Finance and Money News
organicprosperi63
ย 
Ruby-ying Javascript: Avoiding jQuery Spaghetti
Ruby-ying Javascript: Avoiding jQuery SpaghettiRuby-ying Javascript: Avoiding jQuery Spaghetti
Ruby-ying Javascript: Avoiding jQuery Spaghetti
Forrest Chang
ย 
- Php myadmin sql dump-- version 4.0.10.7-- httpwww.php
 - Php myadmin sql dump-- version 4.0.10.7-- httpwww.php - Php myadmin sql dump-- version 4.0.10.7-- httpwww.php
- Php myadmin sql dump-- version 4.0.10.7-- httpwww.php
ssuserfa5723
ย 
UITableView Pain Points
UITableView Pain PointsUITableView Pain Points
UITableView Pain Points
Ken Auer
ย 
Zend framework service
Zend framework serviceZend framework service
Zend framework service
Michelangelo van Dam
ย 
marifatul-insan
marifatul-insanmarifatul-insan
marifatul-insanlargono drs
ย 
Low Carbon Housing for Non-experts
Low Carbon Housing for Non-expertsLow Carbon Housing for Non-experts
Low Carbon Housing for Non-experts
urbed
ย 

What's hot (14)

Actividad 1 de unidad 4
Actividad 1 de unidad 4Actividad 1 de unidad 4
Actividad 1 de unidad 4
ย 
Business News, Personal Finance and Money News
Business News, Personal Finance and Money NewsBusiness News, Personal Finance and Money News
Business News, Personal Finance and Money News
ย 
Milestone 1 FINAL
Milestone 1 FINALMilestone 1 FINAL
Milestone 1 FINAL
ย 
Business News, Personal Finance and Money News
Business News, Personal Finance and Money NewsBusiness News, Personal Finance and Money News
Business News, Personal Finance and Money News
ย 
Modern JavaScript Engine Performance
Modern JavaScript Engine PerformanceModern JavaScript Engine Performance
Modern JavaScript Engine Performance
ย 
Unidad 4 actividad 1
Unidad 4 actividad 1Unidad 4 actividad 1
Unidad 4 actividad 1
ย 
Business News, Personal Finance and Money News
Business News, Personal Finance and Money NewsBusiness News, Personal Finance and Money News
Business News, Personal Finance and Money News
ย 
Ruby-ying Javascript: Avoiding jQuery Spaghetti
Ruby-ying Javascript: Avoiding jQuery SpaghettiRuby-ying Javascript: Avoiding jQuery Spaghetti
Ruby-ying Javascript: Avoiding jQuery Spaghetti
ย 
my_project
my_projectmy_project
my_project
ย 
- Php myadmin sql dump-- version 4.0.10.7-- httpwww.php
 - Php myadmin sql dump-- version 4.0.10.7-- httpwww.php - Php myadmin sql dump-- version 4.0.10.7-- httpwww.php
- Php myadmin sql dump-- version 4.0.10.7-- httpwww.php
ย 
UITableView Pain Points
UITableView Pain PointsUITableView Pain Points
UITableView Pain Points
ย 
Zend framework service
Zend framework serviceZend framework service
Zend framework service
ย 
marifatul-insan
marifatul-insanmarifatul-insan
marifatul-insan
ย 
Low Carbon Housing for Non-experts
Low Carbon Housing for Non-expertsLow Carbon Housing for Non-experts
Low Carbon Housing for Non-experts
ย 

Viewers also liked

Smart suite solution_brief_eng_datasheet
Smart suite solution_brief_eng_datasheetSmart suite solution_brief_eng_datasheet
Smart suite solution_brief_eng_datasheetIITSW Company
ย 
4th Sme Barcelona
4th Sme   Barcelona4th Sme   Barcelona
4th Sme Barcelona
LeonUffi
ย 
Oakland talk
Oakland talkOakland talk
Oakland talk
Joy Hughes
ย 
Introducting Titanium Mobile
Introducting Titanium MobileIntroducting Titanium Mobile
Introducting Titanium MobileAxway Appcelerator
ย 
Gpgpu presentation 2
Gpgpu presentation 2Gpgpu presentation 2
Gpgpu presentation 2
UC Davis
ย 
Gpgpu presentation final
Gpgpu presentation finalGpgpu presentation final
Gpgpu presentation final
UC Davis
ย 
Gpgpu present 1
Gpgpu present 1Gpgpu present 1
Gpgpu present 1
UC Davis
ย 
Joint super resolution and denoising from a single depth image
Joint super resolution and denoising from a single depth imageJoint super resolution and denoising from a single depth image
Joint super resolution and denoising from a single depth image
LogicMindtech Nologies
ย 
Bug Labs Automotive Web
Bug Labs Automotive WebBug Labs Automotive Web
Bug Labs Automotive Web
buglabs
ย 
Bug Labs Gov Web
Bug Labs Gov WebBug Labs Gov Web
Bug Labs Gov Web
buglabs
ย 

Viewers also liked (10)

Smart suite solution_brief_eng_datasheet
Smart suite solution_brief_eng_datasheetSmart suite solution_brief_eng_datasheet
Smart suite solution_brief_eng_datasheet
ย 
4th Sme Barcelona
4th Sme   Barcelona4th Sme   Barcelona
4th Sme Barcelona
ย 
Oakland talk
Oakland talkOakland talk
Oakland talk
ย 
Introducting Titanium Mobile
Introducting Titanium MobileIntroducting Titanium Mobile
Introducting Titanium Mobile
ย 
Gpgpu presentation 2
Gpgpu presentation 2Gpgpu presentation 2
Gpgpu presentation 2
ย 
Gpgpu presentation final
Gpgpu presentation finalGpgpu presentation final
Gpgpu presentation final
ย 
Gpgpu present 1
Gpgpu present 1Gpgpu present 1
Gpgpu present 1
ย 
Joint super resolution and denoising from a single depth image
Joint super resolution and denoising from a single depth imageJoint super resolution and denoising from a single depth image
Joint super resolution and denoising from a single depth image
ย 
Bug Labs Automotive Web
Bug Labs Automotive WebBug Labs Automotive Web
Bug Labs Automotive Web
ย 
Bug Labs Gov Web
Bug Labs Gov WebBug Labs Gov Web
Bug Labs Gov Web
ย 

Similar to Actividad 1

SPOOL output.log DROP TABL.pdf
SPOOL output.log DROP TABL.pdfSPOOL output.log DROP TABL.pdf
SPOOL output.log DROP TABL.pdf
fashionfootwear1
ย 
SQL FILE FROM MOODLEUSE [master]GO Object Databa.pdf
SQL FILE FROM MOODLEUSE [master]GO Object Databa.pdfSQL FILE FROM MOODLEUSE [master]GO Object Databa.pdf
SQL FILE FROM MOODLEUSE [master]GO Object Databa.pdf
arrowit1
ย 
When debugging the code, use Drop table statementsto drop pr.docx
 When debugging the code, use Drop table statementsto drop pr.docx When debugging the code, use Drop table statementsto drop pr.docx
When debugging the code, use Drop table statementsto drop pr.docx
aryan532920
ย 
AskTom Office Hours about Database Migrations
AskTom Office Hours about Database MigrationsAskTom Office Hours about Database Migrations
AskTom Office Hours about Database Migrations
Jasmin Fluri
ย 
Sql commands
Sql commandsSql commands
Sql commands
Christalin Nelson
ย 
Use shop
Use shopUse shop
Use shop
Usukhuu Galaa
ย 
CreaciรณN Tablas En Oracle
CreaciรณN Tablas En OracleCreaciรณN Tablas En Oracle
CreaciรณN Tablas En Oracle
esacre
ย 
Sups
SupsSups
Sups
higauji
ย 
Inventory aging report using oracle discoverer desktop
Inventory aging report using oracle discoverer desktopInventory aging report using oracle discoverer desktop
Inventory aging report using oracle discoverer desktop
Ahmed Elshayeb
ย 
Bronte's Assortment Presentation Slide
Bronte's Assortment Presentation SlideBronte's Assortment Presentation Slide
Bronte's Assortment Presentation Slide
sulabh4
ย 
Quill vs Slick Smackdown
Quill vs Slick SmackdownQuill vs Slick Smackdown
Quill vs Slick Smackdown
Alexander Ioffe
ย 
Shopping mall managent system
Shopping mall managent systemShopping mall managent system
Shopping mall managent system
Syed Hamza
ย 
Fin data model
Fin data modelFin data model
Fin data model
sridhark1981
ย 
on SQL Managment studio(For the following exercise, use the Week 5.pdf
on SQL Managment studio(For the following exercise, use the Week 5.pdfon SQL Managment studio(For the following exercise, use the Week 5.pdf
on SQL Managment studio(For the following exercise, use the Week 5.pdf
formaxekochi
ย 
Fx oracle - AS400
Fx oracle - AS400Fx oracle - AS400
Fx oracle - AS400
Josรฉ Antรณn Napa
ย 
The resto txt Use for TM254 2021J TMA02 Question 6 .pdf
The resto txt     Use for TM254 2021J TMA02 Question 6 .pdfThe resto txt     Use for TM254 2021J TMA02 Question 6 .pdf
The resto txt Use for TM254 2021J TMA02 Question 6 .pdf
giriraj65
ย 
Answer2 (clothing boutique)
Answer2 (clothing boutique)Answer2 (clothing boutique)
Answer2 (clothing boutique)
Nicky Valdo
ย 

Similar to Actividad 1 (20)

SPOOL output.log DROP TABL.pdf
SPOOL output.log DROP TABL.pdfSPOOL output.log DROP TABL.pdf
SPOOL output.log DROP TABL.pdf
ย 
SQL FILE FROM MOODLEUSE [master]GO Object Databa.pdf
SQL FILE FROM MOODLEUSE [master]GO Object Databa.pdfSQL FILE FROM MOODLEUSE [master]GO Object Databa.pdf
SQL FILE FROM MOODLEUSE [master]GO Object Databa.pdf
ย 
When debugging the code, use Drop table statementsto drop pr.docx
 When debugging the code, use Drop table statementsto drop pr.docx When debugging the code, use Drop table statementsto drop pr.docx
When debugging the code, use Drop table statementsto drop pr.docx
ย 
AskTom Office Hours about Database Migrations
AskTom Office Hours about Database MigrationsAskTom Office Hours about Database Migrations
AskTom Office Hours about Database Migrations
ย 
Benforta
BenfortaBenforta
Benforta
ย 
Benforta
BenfortaBenforta
Benforta
ย 
Sql commands
Sql commandsSql commands
Sql commands
ย 
Taller
TallerTaller
Taller
ย 
Use shop
Use shopUse shop
Use shop
ย 
CreaciรณN Tablas En Oracle
CreaciรณN Tablas En OracleCreaciรณN Tablas En Oracle
CreaciรณN Tablas En Oracle
ย 
Sups
SupsSups
Sups
ย 
Inventory aging report using oracle discoverer desktop
Inventory aging report using oracle discoverer desktopInventory aging report using oracle discoverer desktop
Inventory aging report using oracle discoverer desktop
ย 
Bronte's Assortment Presentation Slide
Bronte's Assortment Presentation SlideBronte's Assortment Presentation Slide
Bronte's Assortment Presentation Slide
ย 
Quill vs Slick Smackdown
Quill vs Slick SmackdownQuill vs Slick Smackdown
Quill vs Slick Smackdown
ย 
Shopping mall managent system
Shopping mall managent systemShopping mall managent system
Shopping mall managent system
ย 
Fin data model
Fin data modelFin data model
Fin data model
ย 
on SQL Managment studio(For the following exercise, use the Week 5.pdf
on SQL Managment studio(For the following exercise, use the Week 5.pdfon SQL Managment studio(For the following exercise, use the Week 5.pdf
on SQL Managment studio(For the following exercise, use the Week 5.pdf
ย 
Fx oracle - AS400
Fx oracle - AS400Fx oracle - AS400
Fx oracle - AS400
ย 
The resto txt Use for TM254 2021J TMA02 Question 6 .pdf
The resto txt     Use for TM254 2021J TMA02 Question 6 .pdfThe resto txt     Use for TM254 2021J TMA02 Question 6 .pdf
The resto txt Use for TM254 2021J TMA02 Question 6 .pdf
ย 
Answer2 (clothing boutique)
Answer2 (clothing boutique)Answer2 (clothing boutique)
Answer2 (clothing boutique)
ย 

More from JUAN ENRIQUE

Ensayo normas juan enrique
Ensayo normas juan enriqueEnsayo normas juan enrique
Ensayo normas juan enriqueJUAN ENRIQUE
ย 
Cambio tecnologico luz fm 102
Cambio tecnologico luz fm 102Cambio tecnologico luz fm 102
Cambio tecnologico luz fm 102JUAN ENRIQUE
ย 
Plan estrategico actualizado
Plan estrategico actualizadoPlan estrategico actualizado
Plan estrategico actualizadoJUAN ENRIQUE
ย 
Caso de estudio (capitulo 2)
Caso de estudio (capitulo 2)Caso de estudio (capitulo 2)
Caso de estudio (capitulo 2)JUAN ENRIQUE
ย 
Mapa mental capitulo 8
Mapa mental capitulo 8Mapa mental capitulo 8
Mapa mental capitulo 8JUAN ENRIQUE
ย 
La gestion del contrato mapa mental capitulo 7
La gestion del contrato mapa mental capitulo 7La gestion del contrato mapa mental capitulo 7
La gestion del contrato mapa mental capitulo 7JUAN ENRIQUE
ย 
Caso de estudio unidad 3 capitulo 8
Caso de estudio unidad 3 capitulo 8Caso de estudio unidad 3 capitulo 8
Caso de estudio unidad 3 capitulo 8JUAN ENRIQUE
ย 
Caso de estudio unidad 3 capitulo 7
Caso de estudio unidad 3 capitulo 7Caso de estudio unidad 3 capitulo 7
Caso de estudio unidad 3 capitulo 7JUAN ENRIQUE
ย 
Casi de estudio unidad 3 capitulo 2
Casi de estudio unidad 3 capitulo 2Casi de estudio unidad 3 capitulo 2
Casi de estudio unidad 3 capitulo 2JUAN ENRIQUE
ย 
Justificaciones outsourcings
Justificaciones outsourcingsJustificaciones outsourcings
Justificaciones outsourcingsJUAN ENRIQUE
ย 
Ejemplos de outsourcing
Ejemplos de outsourcingEjemplos de outsourcing
Ejemplos de outsourcingJUAN ENRIQUE
ย 
Ejemplos de outsourcing
Ejemplos de outsourcingEjemplos de outsourcing
Ejemplos de outsourcingJUAN ENRIQUE
ย 
Plan estrategico (gruniski)
Plan estrategico (gruniski)Plan estrategico (gruniski)
Plan estrategico (gruniski)JUAN ENRIQUE
ย 
Plan estrategico (gruniski)
Plan estrategico (gruniski)Plan estrategico (gruniski)
Plan estrategico (gruniski)JUAN ENRIQUE
ย 
Plan estrategico (gruniski)
Plan estrategico (gruniski)Plan estrategico (gruniski)
Plan estrategico (gruniski)JUAN ENRIQUE
ย 
Plan informรกtico Lerma
Plan informรกtico LermaPlan informรกtico Lerma
Plan informรกtico LermaJUAN ENRIQUE
ย 
Plan informatico lerma
Plan informatico lermaPlan informatico lerma
Plan informatico lermaJUAN ENRIQUE
ย 
Plan estrategico empresa
Plan estrategico empresaPlan estrategico empresa
Plan estrategico empresaJUAN ENRIQUE
ย 

More from JUAN ENRIQUE (20)

Ensayo normas juan enrique
Ensayo normas juan enriqueEnsayo normas juan enrique
Ensayo normas juan enrique
ย 
Cambio tecnologico luz fm 102
Cambio tecnologico luz fm 102Cambio tecnologico luz fm 102
Cambio tecnologico luz fm 102
ย 
Plan estrategico actualizado
Plan estrategico actualizadoPlan estrategico actualizado
Plan estrategico actualizado
ย 
Caso de estudio (capitulo 2)
Caso de estudio (capitulo 2)Caso de estudio (capitulo 2)
Caso de estudio (capitulo 2)
ย 
Cemex
CemexCemex
Cemex
ย 
Cemex
CemexCemex
Cemex
ย 
Mapa mental capitulo 8
Mapa mental capitulo 8Mapa mental capitulo 8
Mapa mental capitulo 8
ย 
La gestion del contrato mapa mental capitulo 7
La gestion del contrato mapa mental capitulo 7La gestion del contrato mapa mental capitulo 7
La gestion del contrato mapa mental capitulo 7
ย 
Caso de estudio unidad 3 capitulo 8
Caso de estudio unidad 3 capitulo 8Caso de estudio unidad 3 capitulo 8
Caso de estudio unidad 3 capitulo 8
ย 
Caso de estudio unidad 3 capitulo 7
Caso de estudio unidad 3 capitulo 7Caso de estudio unidad 3 capitulo 7
Caso de estudio unidad 3 capitulo 7
ย 
Casi de estudio unidad 3 capitulo 2
Casi de estudio unidad 3 capitulo 2Casi de estudio unidad 3 capitulo 2
Casi de estudio unidad 3 capitulo 2
ย 
Justificaciones outsourcings
Justificaciones outsourcingsJustificaciones outsourcings
Justificaciones outsourcings
ย 
Ejemplos de outsourcing
Ejemplos de outsourcingEjemplos de outsourcing
Ejemplos de outsourcing
ย 
Ejemplos de outsourcing
Ejemplos de outsourcingEjemplos de outsourcing
Ejemplos de outsourcing
ย 
Plan estrategico (gruniski)
Plan estrategico (gruniski)Plan estrategico (gruniski)
Plan estrategico (gruniski)
ย 
Plan estrategico (gruniski)
Plan estrategico (gruniski)Plan estrategico (gruniski)
Plan estrategico (gruniski)
ย 
Plan estrategico (gruniski)
Plan estrategico (gruniski)Plan estrategico (gruniski)
Plan estrategico (gruniski)
ย 
Plan informรกtico Lerma
Plan informรกtico LermaPlan informรกtico Lerma
Plan informรกtico Lerma
ย 
Plan informatico lerma
Plan informatico lermaPlan informatico lerma
Plan informatico lerma
ย 
Plan estrategico empresa
Plan estrategico empresaPlan estrategico empresa
Plan estrategico empresa
ย 

Recently uploaded

Skye Residences | Extended Stay Residences Near Toronto Airport
Skye Residences | Extended Stay Residences Near Toronto AirportSkye Residences | Extended Stay Residences Near Toronto Airport
Skye Residences | Extended Stay Residences Near Toronto Airport
marketingjdass
ย 
20240425_ TJ Communications Credentials_compressed.pdf
20240425_ TJ Communications Credentials_compressed.pdf20240425_ TJ Communications Credentials_compressed.pdf
20240425_ TJ Communications Credentials_compressed.pdf
tjcomstrang
ย 
Cree_Rey_BrandIdentityKit.PDF_PersonalBd
Cree_Rey_BrandIdentityKit.PDF_PersonalBdCree_Rey_BrandIdentityKit.PDF_PersonalBd
Cree_Rey_BrandIdentityKit.PDF_PersonalBd
creerey
ย 
Accpac to QuickBooks Conversion Navigating the Transition with Online Account...
Accpac to QuickBooks Conversion Navigating the Transition with Online Account...Accpac to QuickBooks Conversion Navigating the Transition with Online Account...
Accpac to QuickBooks Conversion Navigating the Transition with Online Account...
PaulBryant58
ย 
Maksym Vyshnivetskyi: PMO Quality Management (UA)
Maksym Vyshnivetskyi: PMO Quality Management (UA)Maksym Vyshnivetskyi: PMO Quality Management (UA)
Maksym Vyshnivetskyi: PMO Quality Management (UA)
Lviv Startup Club
ย 
chapter 10 - excise tax of transfer and business taxation
chapter 10 - excise tax of transfer and business taxationchapter 10 - excise tax of transfer and business taxation
chapter 10 - excise tax of transfer and business taxation
AUDIJEAngelo
ย 
Filing Your Delaware Franchise Tax A Detailed Guide
Filing Your Delaware Franchise Tax A Detailed GuideFiling Your Delaware Franchise Tax A Detailed Guide
Filing Your Delaware Franchise Tax A Detailed Guide
YourLegal Accounting
ย 
Project File Report BBA 6th semester.pdf
Project File Report BBA 6th semester.pdfProject File Report BBA 6th semester.pdf
Project File Report BBA 6th semester.pdf
RajPriye
ย 
Introduction to Amazon company 111111111111
Introduction to Amazon company 111111111111Introduction to Amazon company 111111111111
Introduction to Amazon company 111111111111
zoyaansari11365
ย 
Attending a job Interview for B1 and B2 Englsih learners
Attending a job Interview for B1 and B2 Englsih learnersAttending a job Interview for B1 and B2 Englsih learners
Attending a job Interview for B1 and B2 Englsih learners
Erika906060
ย 
Set off and carry forward of losses and assessment of individuals.pptx
Set off and carry forward of losses and assessment of individuals.pptxSet off and carry forward of losses and assessment of individuals.pptx
Set off and carry forward of losses and assessment of individuals.pptx
HARSHITHV26
ย 
FINAL PRESENTATION.pptx12143241324134134
FINAL PRESENTATION.pptx12143241324134134FINAL PRESENTATION.pptx12143241324134134
FINAL PRESENTATION.pptx12143241324134134
LR1709MUSIC
ย 
Exploring Patterns of Connection with Social Dreaming
Exploring Patterns of Connection with Social DreamingExploring Patterns of Connection with Social Dreaming
Exploring Patterns of Connection with Social Dreaming
Nicola Wreford-Howard
ย 
Buy Verified PayPal Account | Buy Google 5 Star Reviews
Buy Verified PayPal Account | Buy Google 5 Star ReviewsBuy Verified PayPal Account | Buy Google 5 Star Reviews
Buy Verified PayPal Account | Buy Google 5 Star Reviews
usawebmarket
ย 
Memorandum Of Association Constitution of Company.ppt
Memorandum Of Association Constitution of Company.pptMemorandum Of Association Constitution of Company.ppt
Memorandum Of Association Constitution of Company.ppt
seri bangash
ย 
Enterprise Excellence is Inclusive Excellence.pdf
Enterprise Excellence is Inclusive Excellence.pdfEnterprise Excellence is Inclusive Excellence.pdf
Enterprise Excellence is Inclusive Excellence.pdf
KaiNexus
ย 
Putting the SPARK into Virtual Training.pptx
Putting the SPARK into Virtual Training.pptxPutting the SPARK into Virtual Training.pptx
Putting the SPARK into Virtual Training.pptx
Cynthia Clay
ย 
3.0 Project 2_ Developing My Brand Identity Kit.pptx
3.0 Project 2_ Developing My Brand Identity Kit.pptx3.0 Project 2_ Developing My Brand Identity Kit.pptx
3.0 Project 2_ Developing My Brand Identity Kit.pptx
tanyjahb
ย 
CADAVER AS OUR FIRST TEACHER anatomt in your.pptx
CADAVER AS OUR FIRST TEACHER anatomt in your.pptxCADAVER AS OUR FIRST TEACHER anatomt in your.pptx
CADAVER AS OUR FIRST TEACHER anatomt in your.pptx
fakeloginn69
ย 
Taurus Zodiac Sign_ Personality Traits and Sign Dates.pptx
Taurus Zodiac Sign_ Personality Traits and Sign Dates.pptxTaurus Zodiac Sign_ Personality Traits and Sign Dates.pptx
Taurus Zodiac Sign_ Personality Traits and Sign Dates.pptx
my Pandit
ย 

Recently uploaded (20)

Skye Residences | Extended Stay Residences Near Toronto Airport
Skye Residences | Extended Stay Residences Near Toronto AirportSkye Residences | Extended Stay Residences Near Toronto Airport
Skye Residences | Extended Stay Residences Near Toronto Airport
ย 
20240425_ TJ Communications Credentials_compressed.pdf
20240425_ TJ Communications Credentials_compressed.pdf20240425_ TJ Communications Credentials_compressed.pdf
20240425_ TJ Communications Credentials_compressed.pdf
ย 
Cree_Rey_BrandIdentityKit.PDF_PersonalBd
Cree_Rey_BrandIdentityKit.PDF_PersonalBdCree_Rey_BrandIdentityKit.PDF_PersonalBd
Cree_Rey_BrandIdentityKit.PDF_PersonalBd
ย 
Accpac to QuickBooks Conversion Navigating the Transition with Online Account...
Accpac to QuickBooks Conversion Navigating the Transition with Online Account...Accpac to QuickBooks Conversion Navigating the Transition with Online Account...
Accpac to QuickBooks Conversion Navigating the Transition with Online Account...
ย 
Maksym Vyshnivetskyi: PMO Quality Management (UA)
Maksym Vyshnivetskyi: PMO Quality Management (UA)Maksym Vyshnivetskyi: PMO Quality Management (UA)
Maksym Vyshnivetskyi: PMO Quality Management (UA)
ย 
chapter 10 - excise tax of transfer and business taxation
chapter 10 - excise tax of transfer and business taxationchapter 10 - excise tax of transfer and business taxation
chapter 10 - excise tax of transfer and business taxation
ย 
Filing Your Delaware Franchise Tax A Detailed Guide
Filing Your Delaware Franchise Tax A Detailed GuideFiling Your Delaware Franchise Tax A Detailed Guide
Filing Your Delaware Franchise Tax A Detailed Guide
ย 
Project File Report BBA 6th semester.pdf
Project File Report BBA 6th semester.pdfProject File Report BBA 6th semester.pdf
Project File Report BBA 6th semester.pdf
ย 
Introduction to Amazon company 111111111111
Introduction to Amazon company 111111111111Introduction to Amazon company 111111111111
Introduction to Amazon company 111111111111
ย 
Attending a job Interview for B1 and B2 Englsih learners
Attending a job Interview for B1 and B2 Englsih learnersAttending a job Interview for B1 and B2 Englsih learners
Attending a job Interview for B1 and B2 Englsih learners
ย 
Set off and carry forward of losses and assessment of individuals.pptx
Set off and carry forward of losses and assessment of individuals.pptxSet off and carry forward of losses and assessment of individuals.pptx
Set off and carry forward of losses and assessment of individuals.pptx
ย 
FINAL PRESENTATION.pptx12143241324134134
FINAL PRESENTATION.pptx12143241324134134FINAL PRESENTATION.pptx12143241324134134
FINAL PRESENTATION.pptx12143241324134134
ย 
Exploring Patterns of Connection with Social Dreaming
Exploring Patterns of Connection with Social DreamingExploring Patterns of Connection with Social Dreaming
Exploring Patterns of Connection with Social Dreaming
ย 
Buy Verified PayPal Account | Buy Google 5 Star Reviews
Buy Verified PayPal Account | Buy Google 5 Star ReviewsBuy Verified PayPal Account | Buy Google 5 Star Reviews
Buy Verified PayPal Account | Buy Google 5 Star Reviews
ย 
Memorandum Of Association Constitution of Company.ppt
Memorandum Of Association Constitution of Company.pptMemorandum Of Association Constitution of Company.ppt
Memorandum Of Association Constitution of Company.ppt
ย 
Enterprise Excellence is Inclusive Excellence.pdf
Enterprise Excellence is Inclusive Excellence.pdfEnterprise Excellence is Inclusive Excellence.pdf
Enterprise Excellence is Inclusive Excellence.pdf
ย 
Putting the SPARK into Virtual Training.pptx
Putting the SPARK into Virtual Training.pptxPutting the SPARK into Virtual Training.pptx
Putting the SPARK into Virtual Training.pptx
ย 
3.0 Project 2_ Developing My Brand Identity Kit.pptx
3.0 Project 2_ Developing My Brand Identity Kit.pptx3.0 Project 2_ Developing My Brand Identity Kit.pptx
3.0 Project 2_ Developing My Brand Identity Kit.pptx
ย 
CADAVER AS OUR FIRST TEACHER anatomt in your.pptx
CADAVER AS OUR FIRST TEACHER anatomt in your.pptxCADAVER AS OUR FIRST TEACHER anatomt in your.pptx
CADAVER AS OUR FIRST TEACHER anatomt in your.pptx
ย 
Taurus Zodiac Sign_ Personality Traits and Sign Dates.pptx
Taurus Zodiac Sign_ Personality Traits and Sign Dates.pptxTaurus Zodiac Sign_ Personality Traits and Sign Dates.pptx
Taurus Zodiac Sign_ Personality Traits and Sign Dates.pptx
ย 

Actividad 1

  • 1. BASE DE DATOS DE BANCO ACTIVIDAD 1 Create Departments table CREATE TABLE Departments ( dept_id varchar(10) NOT NULL , dept_name varchar(20) NOT NULL ); CREATE TABLE ProductType ( product_type_id varchar(10) NOT NULL , product_type_name varchar(50) NOT NULL ); CREATE TABLE Product ( product_id varchar(10) NOT NULL , product_name varchar(50) NOT NULL , Product_type_id varchar(10) NOT NULL , date_offered datetime NOT NULL, date_retired datetime NOT NULL ); CREATE TABLE Account ( account_id Integer NOT NULL , product_id varchar(10) NOT NULL , custom_id integer NOT NULL , open_date date NOT NULL , close_date date NOT NULL , last_activity date NOT NULL , account_status varchar(10) NULL, branch_id varchar(10) NOT NULL, emp_id varchar(10) NOT NULL, avail_balance float NOT NULL, pending_balance float NOT NULL ); CREATE TABLE Customer ( custom_id integer NOT NULL , custom_type char(2) NOT NULL, fed_id varchar(12) NOT NULL , custom_address varchar(30) NULL , custom_city varchar(20) NULL ,
  • 2. custom_state varchar(20) NULL , custom_zip varchar(10) NULL ); CREATE TABLE Business ( busi_id char(10) NOT NULL , custom_id integer NOT NULL , busi_name varchar(40) NOT NULL , vend_state char(5) NULL , incorp_date date NOT NULL ); CREATE TABLE Officer ( officer_id varchar(10) NOT NULL , custom_id integer NOT NULL , first_name varchar(30) NOT NULL , last_name varchar(30) NOT NULL , starts_date date NOT NULL , end_date date NOT NULL ); CREATE TABLE Individual ( individual_id char(10) NOT NULL , custom_id integer NOT NULL , f_name varchar(30) NOT NULL , l_name varchar(30) NOT NULL , birth_date date NOT NULL ); CREATE TABLE Transactions ( txn_id integer NOT NULL , txn_date datetime NOT NULL , account_id integer NOT NULL , txn_cd varchar(10) NOT NULL , amount decimal(10,2) NULL , emp_id varchar(10) NOT NULL , branch_id varchar(10) NOT NULL , funds_avail date NOT NULL ); CREATE TABLE Employee (
  • 3. emp_id varchar(10) NOT NULL , fname varchar(20) NOT NULL , lname varchar(20) NOT NULL , s_date date NOT NULL , e_date date NOT NULL , superior_emp_id varchar(10) NOT NULL , dept_id smallint NOT NULL , tit varchar(20) NULL, branch_id smallint NOT NULL ); CREATE TABLE Branch ( branch_id varchar(10) NOT NULL, branch_name varchar(20) NOT NULL , branch_address char(30) NULL , branch_city char(20) NULL , branch_state varchar(20) NULL , branch_zip char(12) NULL );------------------------- ---------------------- -- Define primary keys ---------------------- ALTER TABLE Customer WITH NOCHECK ADD CONSTRAINT PK_Customer PRIMARY KEY CLUSTERED (custom_id); ALTER TABLE Branch WITH NOCHECK ADD CONSTRAINT PK_Branch PRIMARY KEY CLUSTERED (branch_id); ALTER TABLE Product_type WITH NOCHECK ADD CONSTRAINT PK_Product_type PRIMARY KEY CLUSTERED (product_type_id); ALTER TABLE Product WITH NOCHECK ADD CONSTRAINT PK_Product PRIMARY KEY CLUSTERED (product_id); ALTER TABLE Account WITH NOCHECK ADD CONSTRAINT PK_Account PRIMARY KEY CLUSTERED (account_id); ALTER TABLE Officer WITH NOCHECK ADD CONSTRAINT PK_Officer PRIMARY KEY CLUSTERED (officer_id); ALTER TABLE Business WITH NOCHECK ADD CONSTRAINT PK_Business PRIMARY KEY CLUSTERED (busi_id); ALTER TABLE Individual WITH NOCHECK ADD CONSTRAINT PK_Individual PRIMARY KEY CLUSTERED (individual_id); ALTER TABLE Employee WITH NOCHECK ADD CONSTRAINT PK_Employee PRIMARY KEY CLUSTERED (emp_id); ALTER TABLE Transactions WITH NOCHECK ADD CONSTRAINT PK_Transactions PRIMARY KEY CLUSTERED (txn_id); ALTER TABLE Deparments WITH NOCHECK ADD CONSTRAINT PK_Departments PRIMARY KEY CLUSTERED (dept_id); ---------------------- -- Define foreign keys ----------------------
  • 4. ALTER TABLE Product ADD CONSTRAINT FK_Product_ProductType FOREIGN KEY (product_type_id) REFERENCES ProductType (product_type_id); ALTER TABLE Account ADD CONSTRAINT FK_Account_Product FOREIGN KEY (product_id) REFERENCES Product (product_id), CONSTRAINT FK_Account_Customer FOREIGN KEY (custom_id) REFERENCES Customer (custom_id), CONSTRAINT FK_Account_Branch FOREIGN KEY (branch_id) REFERENCES Branch (branch_id), CONSTRAINT FK_Account_Employee FOREIGN KEY (emp_id) REFERENCES Employee (emp_id); ALTER TABLE Business ADD CONSTRAINT FK_Business_Customer FOREIGN KEY (custom_id) REFERENCES Customer (custom_id); ALTER TABLE Individual ADD CONSTRAINT FK_Individual_Customer FOREIGN KEY (custom_id) REFERENCES Customer (custom_id); ALTER TABLE Officer ADD CONSTRAINT FK_Officer_Customer FOREIGN KEY (custom_id) REFERENCES Customer (custom_id); ALTER TABLE Transactions ADD CONSTRAINT FK_Transactions_Account FOREIGN KEY (account_id) REFERENCES Account (account_id), CONSTRAINT FK_Transactions_Employee FOREIGN KEY (emp_id) REFERENCES Employee (emp_id), CONSTRAINT FK_Transactions_Branch FOREIGN KEY (branch_id) REFERENCES Branch (branch_id); ALTER TABLE Employee ADD CONSTRAINT FK_Employee_Departments FOREIGN KEY (dept_id) REFERENCES Deparments (dept_id), CONSTRAINT FK_Employee_Employee FOREIGN KEY (superior_emp_id) REFERENCES Employee (superior_emp_id), CONSTRAINT FK_Employee_Branch FOREIGN KEY (branch_id) REFERENCES Branch (branch_id); CREATE TABLE Departments ( dept_id smallint NOT NULL , dept_name varchar(20) NOT NULL ); INSERT INTO Departaments(dept_id, dept_name) VALUES(501, 'sistema') INSERT INTO Departaments(dept_id, dept_name) VALUES(502, 'gerencia') INSERT INTO Departaments(dept_id, dept_name) VALUES(503, 'contabilidad') INSERT INTO Departaments(dept_id, dept_name) VALUES(504, 'administracion') INSERT INTO Departaments(dept_id, dept_name) VALUES(505, 'recursos humanos') INSERT INTO Departaments(dept_id, dept_name) VALUES(506, 'tramites') INSERT INTO Departaments(dept_id, dept_name)
  • 5. VALUES(507, 'atencion a cliente' ) INSERT INTO Departaments(dept_id, dept_name) VALUES(508, 'cajas' ) INSERT INTO Departaments(dept_id, dept_name) VALUES(509, 'creditos') INSERT INTO Departaments(dept_id, dept_name) VALUES(510, 'hipotecaria') INSERT INTO Departaments(dept_id, dept_name) VALUES(511, 'seguridad') INSERT INTO Departaments(dept_id, dept_name) VALUES(512, 'limpieza') INSERT INTO Departaments(dept_id, dept_name) VALUES(513, 'finanzas') INSERT INTO Departaments(dept_id, dept_name) VALUES(514, 'publicidad') INSERT INTO Departaments(dept_id, dept_name) VALUES(515, 'juridico') INSERT INTO Departaments(dept_id, dept_name) VALUES(516, 'control de calidad') INSERT INTO Departaments(dept_id, dept_name) VALUES(517, 'transacciones') INSERT INTO Departaments(dept_id, dept_name) VALUES(518, 'cobranzas') CREATE TABLE Customer ( custom_id integer NOT NULL , custom_type char(2) NOT NULL, fed_id varchar(12) NOT NULL , custom_address varchar(30) NULL , custom_city varchar(20) NULL , custom_state varchar(20) NULL , custom_zip varchar(10) NULL ); INSERT INTO Customer(custom_id, custom_type,fed_id,custom_address,custom_city,custom_state,custom_zip) VALUES('0001', 'ep', '00012341', 'reforma #145', 'mexico', 'veracruz', '95400'); INSERT INTO Customer(custom_id, custom_type,fed_id,custom_address,custom_city,custom_state,custom_zip) VALUES('0002', 'pl', '00012342', 'carpio #43', 'mexico', 'guadalajara', '94670'); INSERT INTO Customer(custom_id, custom_type,fed_id,custom_address,custom_city,custom_state,custom_zip) VALUES('0003','pr', '00012343', 'libertad #1136', 'mexico', 'xalapa', '45678'); INSERT INTO Customer(custom_id, custom_type,fed_id,custom_address,custom_city,custom_state,custom_zip) VALUES('0004', 'hm', '00012344', 'campo real #717', 'mexico', 'monterrey', '45678'); INSERT INTO Customer(custom_id, custom_type,fed_id,custom_address,custom_city,custom_state,custom_zip) VALUES('0005', 'pl', '00012345', 'ruiz cortinez #67', 'mexico', 'veracruz', '95400'); INSERT INTO Customer(custom_id, custom_type,fed_id,custom_address,custom_city,custom_state,custom_zip) VALUES('0006', 'ep', '00012346', 'diaz miron #654', 'mexico', 'veracruz', '95400');
  • 6. INSERT INTO Customer(custom_id, custom_type,fed_id,custom_address,custom_city,custom_state,custom_zip) VALUES('0007', 'hm', '00012347', '2 de abril #245', 'mexico', 'yucatan', '45673'); INSERT INTO Customer(custom_id, custom_type,fed_id,custom_address,custom_city,custom_state,custom_zip) VALUES('0008', 'pr', '00012348', '20 de noviembre #1678', 'mexico', 'guanajuato', '56433'); INSERT INTO Customer(custom_id, custom_type,fed_id,custom_address,custom_city,custom_state,custom_zip) VALUES('0009', 'pl', '00012349', 'murillo vidal #25', 'mexico', 'veracruz', '95400'); INSERT INTO Customer(custom_id, custom_type,fed_id,custom_address,custom_city,custom_state,custom_zip) VALUES('0010', 'ep', '00012351', 'arriola molina #456', 'mexico', 'xalapa', '45678'); CREATE TABLE Officer ( officer_id varchar(10) NOT NULL , custom_id integer NOT NULL , first_name varchar(30) NOT NULL , last_name varchar(30) NOT NULL , starts_date date NOT NULL , end_date date NOT NULL ); INSERT INTO Officer(officer_id, custom_id, first_name, last_name, starts_date, end_date) VALUES('1000', '0001', 'roberto', 'meguelle', '2010/08/03', '2010/12/31'); INSERT INTO Officer(officer_id, custom_id, first_name, last_name, starts_date, end_date) VALUES('2000', '0002', 'juan carlos', 'vidal', '1990/10/23', '1995/05/29'); INSERT INTO Officer(officer_id, custom_id, first_name, last_name, starts_date, end_date) VALUES('3000', '0003', 'fernando', 'guzman', '2010/01/03', '2010/08/16'); INSERT INTO Officer(officer_id, custom_id, first_name, last_name, starts_date, end_date) VALUES('4000', '0004', 'enrique', 'rodriguez', '2010/05/07', '2010/07/12'); INSERT INTO Officer(officer_id, custom_id, first_name, last_name, starts_date, end_date) VALUES('5000', '0005', 'jose', 'mimendi', '2010/02/14', '2010/03/19'); INSERT INTO Officer(officer_id, custom_id, first_name, last_name, starts_date, end_date) VALUES('6000', '0006', 'ivan', 'nicanor', '2000/09/12', '2003/12/17'); INSERT INTO Officer(officer_id, custom_id, first_name, last_name, starts_date, end_date) VALUES('7000', '0007', 'jonathan', 'nieto', '2008/05/18', '2010/11/22'); INSERT INTO Officer(officer_id, custom_id, first_name, last_name, starts_date, end_date) VALUES('8000', '0008', 'julian', 'hernandez', '2003/10/16', '2005/09/11'); INSERT INTO Officer(officer_id, custom_id, first_name, last_name, starts_date, end_date) VALUES('9000', '0009', 'arturo', 'lopez', '2010/01/03', '2010/12/31'); INSERT INTO Officer(officer_id, custom_id, first_name, last_name, starts_date, end_date) VALUES('1100', '0010', 'noe', 'avila', '2007/07/25', '2010/11/20'); CREATE TABLE Business ( busi_id char(10) NOT NULL , custom_id integer NOT NULL , busi_name varchar(40) NOT NULL , vend_state char(5) NULL ,
  • 7. incorp_date date NOT NULL ); INSERT INTO Business(busi_id, custom_id, busi_name, vend_state, incorp_date) VALUES('123451', '0001', 'tramite tarjeta', 'ver', '2010/09/10'); INSERT INTO Business(busi_id, custom_id, busi_name, vend_state, incorp_date) VALUES('123452', '0002', 'asesoria bancaria', 'gdl', '2003/06/19'); INSERT INTO Business(busi_id, custom_id, busi_name, vend_state, incorp_date) VALUES('123453', '0003', 'cuenta cheques', 'xlp', '2001/01/22'); INSERT INTO Business(busi_id, custom_id, busi_name, vend_state, incorp_date) VALUES('123454', '0004', 'tramite tarjeta', 'mty', '2006/01/11'); INSERT INTO Business(busi_id, custom_id, busi_name, vend_state, incorp_date) VALUES('123455', '0005', 'cancelacion', 'ver', '2006/04/24'); INSERT INTO Business(busi_id, custom_id, busi_name, vend_state, incorp_date) VALUES('123456', '0006', 'deposito', 'ver', '2010/06/15'); INSERT INTO Business(busi_id, custom_id, busi_name, vend_state, incorp_date) VALUES('123457', '0007', 'retiro en efectivo', 'mex', '2009/10/24'); INSERT INTO Business(busi_id, custom_id, busi_name, vend_state, incorp_date) VALUES('123458', '0008', 'tramite de tarjeta', 'ver', '2008/07/09'); INSERT INTO Business(busi_id, custom_id, busi_name, vend_state, incorp_date) VALUES('123459', '0009', 'deposito', 'gdl', '2010/08/08'); INSERT INTO Business(busi_id, custom_id, busi_name, vend_state, incorp_date) VALUES('123461', '0010', 'cuenta cheques', 'mex', '2000/09/10'); CREATE TABLE Individual ( individual_id char(10) NOT NULL , custom_id integer NOT NULL , f_name varchar(30) NOT NULL , l_name varchar(30) NOT NULL , birth_date date NOT NULL ); INSERT INTO Individual(individual_id, custom_id, f_name, l_name, birth_date) VALUES('10131', '0001', 'monica','lorenzo', '1984/09/11'); INSERT INTO Individual(individual_id, custom_id,f_name, l_name, birth_date) VALUES('10132', '0002', 'mariana', 'camara', '1986/11/23'); INSERT INTO Individual(individual_id, custom_id, f_name, l_name, birth_date) VALUES('10133', '0003', 'victor', 'vidal', '1990/03/15'); INSERT INTO Individual(individual_id, custom_id, f_name, l_name, birth_date) VALUES('10134', '0004', 'manuel', 'hernandez', '1970/07/17'); INSERT INTO Individual(individual_id, custom_id, f_name, l_name, birth_date) VALUES('10135', '0005', 'gonzalo', 'nicanor', '1978/01/05'); INSERT INTO Individual(individual_id, custom_id, f_name, l_name, birth_date) VALUES('10136', '0006', 'daniel', 'limon', '1976/02/14'); INSERT INTO Individual(individual_id, custom_id, f_name, l_name, birth_date) VALUES('10137', '0007', 'lorena', 'perez', '1979/11/11'); INSERT INTO Individual(individual_id, custom_id, f_name, l_name, birth_date) VALUES('10138', '0008', 'zamara', 'moreno', '1984/03/22');
  • 8. INSERT INTO Individual(individual_id, custom_id, f_name, l_name, birth_date) VALUES('10139', '0009', 'saul', 'zamorano', '1989/12/01'); INSERT INTO Individual(individual_id, custom_id, f_name, l_name, birth_date) VALUES('10140', '0010', 'johnny', 'granda', '1978/07/01'); CREATE TABLE Transactions ( txn_id integer NOT NULL , txn_date datetime NOT NULL , account_id integer NOT NULL , txn_cd varchar(10) NOT NULL , amount decimal(10,2) NULL , emp_id varchar(10) NOT NULL , branch_id varchar(10) NOT NULL , funds_avail date NOT NULL ); INSERT INTO Transactions (txn_id,txn_date,account_id,txn_cd,amount,emp_id,branch_id,funds_avail) VALUES(00001,'2005-02-22',101,'CDT','1000.00',1,901,'2005-02-22'); INSERT INTO Transactions(txn_id,txn_date,account_id,txn_cd,amount,emp_id,branch_id,funds_avail) VALUES(00002,'2005-02-23',102,'CDT','525.75',2,902,'2005-02-23'); INSERT INTO Transactions (txn_id,txn_date,account_id,txn_cd,amount,emp_id,branch_id,funds_avail) VALUES(00003,'2005-02-24',103,'DBT','100.00',3,903,'2005-02-24'); INSERT INTO Transactions (txn_id,txn_date,account_id,txn_cd,amount,emp_id,branch_id,funds_avail) VALUES(00004,'2005-02-24',104,'CDT','55',4,904,'2005-02-25'); INSERT INTO Transactions (txn_id,txn_date,account_id,txn_cd,amount,emp_id,branch_id,funds_avail) VALUES(00005,'2005-02-25',105,'DBT','50',5,905,'2005-02-26'); INSERT INTO Transactions (txn_id,txn_date,account_id,txn_cd,amount,emp_id,branch_id,funds_avail) VALUES(00007,'2005-02-25',107,'CDT','125.37',6,906,'2005-02-27'); INSERT INTO Transactions (txn_id,txn_date,account_id,txn_cd,amount,emp_id,branch_id,funds_avail) VALUES(00008,'2005-02-26',108,'DBT','10',7,907,'2005-02-28'); INSERT INTO Transactions (txn_id,txn_date,account_id,txn_cd,amount,emp_id,branch_id,funds_avail) VALUES(00009,'2005-02-27',109,'CDT','75',8,908,'2005-02-29'); CREATE TABLE Account ( account_id Integer NOT NULL , product_id varchar(10) NOT NULL , custom_id integer NOT NULL , open_date date NOT NULL , close_date date NOT NULL , last_activity date NOT NULL ,
  • 9. account_status varchar(10) NULL, branch_id varchar(10) NOT NULL, emp_id varchar(10) NOT NULL, avail_balance float NOT NULL, pending_balance float NOT NULL ); INSERT INTO Account(account_id,product_id,custom_id,open_date,close_date,last_activity,account_status,branc h_id,emp_id,avail_balance,pending_balance) VALUES(101,20001,0001,'2005-02-22','2005-03-02','2005-05-11','active',901,1,'1000.00','200'); INSERT INTO Account(account_id,product_id,custom_id,open_date,close_date,last_activity,account_status,branc h_id,emp_id,avail_balance,pending_balance) VALUES(102,20002,0002,'2005-02-23','2005-03-03','2005-05-12','active',902,2,'1000.00','200'); INSERT INTO Account(account_id,product_id,custom_id,open_date,close_date,last_activity,account_status,branc h_id,emp_id,avail_balance,pending_balance) VALUES(103,20003,0003,'2005-02-24','2005-03-04','2005-05-13','active',903,3,'1000.00','200'); INSERT INTO Account(account_id,product_id,custom_id,open_date,close_date,last_activity,account_status,branc h_id,emp_id,avail_balance,pending_balance) VALUES(104,20004,0004,'2005-02-25','2005-03-05','2005-05-14','active',904,4,'1000.00','200'); INSERT INTO Account(account_id,product_id,custom_id,open_date,close_date,last_activity,account_status,branc h_id,emp_id,avail_balance,pending_balance) VALUES(105,20005,0005,'2005-02-26','2005-03-06','2005-05-15','inactive',905,5,'1000.00','200'); INSERT INTO Account(account_id,product_id,custom_id,open_date,close_date,last_activity,account_status,branc h_id,emp_id,avail_balance,pending_balance) VALUES(107,20006,0006,'2005-02-27','2005-04-07','2005-05-15','inactive',906,6,'1000.00','200'); INSERT INTO Account(account_id,product_id,custom_id,open_date,close_date,last_activity,account_status,branc h_id,emp_id,avail_balance,pending_balance) VALUES(108,20007,0007,'2005-02-28','2005-04-08','2005-05-16','inactive',907,7,'1000.00','200'); INSERT INTO Account(account_id,product_id,custom_id,open_date,close_date,last_activity,account_status,branc h_id,emp_id,avail_balance,pending_balance) VALUES(109,20009,0008,'2005-02-29','2005-04-09','2005-05-17','inactive',908,8,'1000.00','200'); CREATE TABLE Employee ( emp_id varchar(10) NOT NULL , fname varchar(20) NOT NULL , lname varchar(20) NOT NULL , s_date date NOT NULL , e_date date NOT NULL , superior_emp_id varchar(10) NOT NULL , dept_id smallint NOT NULL , tit varchar(20) NULL, branch_id smallint NOT NULL );
  • 10. INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id, dept_id,tit,branch_id) VALUES(1, 'Michael','Smith','2005-04-03','2008-04-03',801,501,'informatica',901); INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id, dept_id,tit,branch_id) VALUES(2, 'Susan','Barker','2005-04-03','2008-04-03',802,502,'gerente',902); INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id, dept_id,tit,branch_id) VALUES(3, 'Robert','Tyler','2005-04-03','2008-04-03',803,503,'contador',903); INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id, dept_id,tit,branch_id) VALUES(4, 'Susan','Hawthorne','2005-04-03','2008-04-03',805,504,'gerente',904); INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id, dept_id,tit,branch_id) VALUES(5, 'John','Gooding','2005-04-03','2008-04-03',805,505,'acesor',905); INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id, dept_id,tit,branch_id) VALUES(6, 'Helen','Fleming','2005-04-03','2008-04-03',806,506,'acesor de tramites',906); INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id, dept_id,tit,branch_id) VALUES(7, 'Chris','Tucker','2005-04-03','2008-04-03',807,507,'operador',907); INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id, dept_id,tit,branch_id) VALUES(8, 'Sarah','Parker','2005-04-03','2008-04-03',808,508,'cajero',908); INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id, dept_id,tit,branch_id) VALUES(9, 'Jane','Grossman','2005-04-03','2008-04-03',809,509,'ejecutivo',909); INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id, dept_id,tit,branch_id) VALUES(10, 'Paula','Roberts','2005-04-03','2008-04-03',810,510,'abogado',910); INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id, dept_id,tit,branch_id) VALUES(11, 'Thomas','Ziegler','2005-04-03','2008-04-03',811,511,'policia',911); INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id, dept_id,tit,branch_id) VALUES(12, 'Samantha','Jameson','2005-04-03','2008-04-03',812,512,'intendente',913); INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id, dept_id,tit,branch_id) VALUES(13, 'John','Blake','2005-04-03','2008-04-03',813,513,'ejecutivo',914); INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id, dept_id,tit,branch_id) VALUES(14, 'Cindy','Mason','2005-04-03','2008-04-03',814,514,'diseรฑador',915); INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id, dept_id,tit,branch_id) VALUES(15, 'Frank','Portmant','2005-04-03','2008-04-03',815,515,'abogado',915); INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id, dept_id,tit,branch_id) VALUES(16, 'Theresa','Markham','2005-04-03','2008-04-03',816,516,'acesor',916); INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id, dept_id,tit,branch_id) VALUES(17, 'Beth','Fowler','2005-04-03','2008-04-03',817,517,'ejecutivo',917); INSERT INTO Employee(emp_id,fname,lname,s_date,e_date,superior_emp_id, dept_id,tit,branch_id) VALUES(18, 'Rick','Tulman','2005-04-03','2008-04-03',818,518,'cobrador',918);
  • 11. CREATE TABLE ProductType ( product_type_id varchar(10) NOT NULL , product_type_name varchar(50) NOT NULL ); INSERT INTO ProductType( product_type_id ,product_type_name) VALUES(601,'credito'); INSERT INTO ProductType( product_type_id ,product_type_name) VALUES(602,'debito'); INSERT INTO ProductType( product_type_id ,product_type_name) VALUES(603,'platino'); INSERT INTO ProductType( product_type_id ,product_type_name) VALUES(604,'dorada'); INSERT INTO ProductType( product_type_id ,product_type_name) VALUES(605,'empresarial'); INSERT INTO ProductType( product_type_id ,product_type_name) VALUES(606,'preferente'); INSERT INTO ProductType( product_type_id ,product_type_name) VALUES(607,'credito'); INSERT INTO ProductType( product_type_id ,product_type_name) VALUES(608,'debito'); INSERT INTO ProductType( product_type_id ,product_type_name) VALUES(609,'platino'); INSERT INTO ProductType( product_type_id ,product_type_name) VALUES(610,'preferente'); INSERT INTO ProductType( product_type_id ,product_type_name) VALUES(611,'empresarial'); INSERT INTO ProductType( product_type_id ,product_type_name) VALUES(612,'dorada'); INSERT INTO ProductType( product_type_id ,product_type_name) VALUES(613,'credito'); INSERT INTO ProductType( product_type_id ,product_type_name) VALUES(614,'debito'); INSERT INTO ProductType( product_type_id ,product_type_name) VALUES(615,'empresarial'); INSERT INTO ProductType( product_type_id ,product_type_name) VALUES(616,'platino'); INSERT INTO ProductType( product_type_id ,product_type_name) VALUES(617,'dorada'); INSERT INTO ProductType( product_type_id ,product_type_name) VALUES(618,'credito'); CREATE TABLE Product ( product_id varchar(10) NOT NULL , product_name varchar(50) NOT NULL , Product_type_id varchar(10) NOT NULL , date_offered datetime NOT NULL, date_retired datetime NOT NULL
  • 12. ); INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired) VALUES(20001,'tarjeta',601,'2005-01-28','2006-01-05'); INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired) VALUES(20002,'tarjeta',602,'2005-02-28','2006-02-06'); INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired) VALUES(20003,'tarjeta',603,'2005-03-28','2006-03-07'); INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired) VALUES(20004,'tarjeta',604,'2005-04-28','2006-04-11'); INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired) VALUES(20005,'tarjeta',605,'2005-05-28','2006-05-30'); INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired) VALUES(20006,'tarjeta',606,'2005-06-28','2006-06-24'); INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired) VALUES(20007,'tarjeta',607,'2005-07-28','2006-07-28'); INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired) VALUES(20008,'tarjeta',608,'2005-08-28','2006-08-14'); INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired) VALUES(20009,'tarjeta',609,'2005-09-28','2006-09-16'); INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired) VALUES(20010,'tarjeta',610,'2005-10-28','2006-10-15'); INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired) VALUES(20011,'tarjeta',611,'2005-11-28','2006-11-13'); INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired) VALUES(20012,'tarjeta',612,'2005-12-28','2006-12-29'); INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired) VALUES(20013,'tarjeta',613,'2005-01-28','2006-02-28'); INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired) VALUES(20014,'tarjeta',614,'2005-02-28','2006-03-31'); INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired) VALUES(20015,'tarjeta',615,'2005-03-28','2006-04-19'); INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired) VALUES(20016,'tarjeta',616,'2005-04-28','2006-05-02'); INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired) VALUES(20017,'tarjeta',617,'2005-05-28','2006-06-08'); INSERT INTO Product( product_id, product_name, product_type_id,date_offered,date_retired) VALUES(20018,'tarjeta',618,'2005-06-28','2006-07-12'); CREATE TABLE Branch ( branch_id varchar(10) NOT NULL, branch_name varchar(20) NOT NULL , branch_address char(30) NULL , branch_city char(20) NULL , branch_state varchar(20) NULL , branch_zip char(12) NULL ); INSERT INTO Branch( branch_id, branch_name, branch_address, branch_city,branch_state,branch_zip) VALUES(901,'diaz miron','diaz miron #655','veracruz','veracruz','91700');
  • 13. INSERT INTO Branch( branch_id, branch_name, branch_address, branch_city,branch_state,branch_zip) VALUES(902,'independencia','independencia #273','veracruz','veracruz','91710' ); INSERT INTO Branch( branch_id, branch_name, branch_address, branch_city,branch_state,branch_zip) VALUES(903,'ruiz cortinez','ruiz cortinez #949','veracruz','veracruz','91720'); INSERT INTO Branch( branch_id, branch_name, branch_address, branch_city,branch_state,branch_zip) VALUES(904,'2 de abril','2 de abril #399','veracruz','veracruz','91730'); INSERT INTO Branch( branch_id, branch_name, branch_address, branch_city,branch_state,branch_zip) VALUES(905,'20 de noviembre','diaz miron #8838','veracruz','veracruz','91740'); INSERT INTO Branch( branch_id, branch_name, branch_address, branch_city,branch_state,branch_zip) VALUES(906,'bolivar','bolivar #427','veracruz','veracruz','91750'); INSERT INTO Branch( branch_id, branch_name, branch_address, branch_city,branch_state,branch_zip) VALUES(907,'reforma','reforma #345','veracruz','veracruz','91760'); INSERT INTO Branch( branch_id, branch_name, branch_address, branch_city,branch_state,branch_zip) VALUES(908,'juan pablo II','juan pablo II #8060','veracruz','veracruz','91770'); INSERT INTO Branch( branch_id, branch_name, branch_address, branch_city,branch_state,branch_zip) VALUES(909,'costa verde','costa verde #6780','veracruz','veracruz','91780'); INSERT INTO Branch( branch_id, branch_name, branch_address, branch_city,branch_state,branch_zip) VALUES(910,'costa de oro','costa de oro #523','veracruz','veracruz','91790'); INSERT INTO Branch( branch_id, branch_name, branch_address, branch_city,branch_state,branch_zip) VALUES(911,'cuauhtemoc','cuauhtemoc #499','veracruz','veracruz','91800'); INSERT INTO Branch( branch_id, branch_name, branch_address, branch_city,branch_state,branch_zip) VALUES(912,'miguel aleman','miguel aleman #324','veracruz','veracruz','91810'); INSERT INTO Branch( branch_id, branch_name, branch_address, branch_city,branch_state,branch_zip) VALUES(913,'circunvalacion','circunvalacion #7011','veracruz','veracruz','91820'); INSERT INTO Branch( branch_id, branch_name, branch_address, branch_city,branch_state,branch_zip) VALUES(914,'la fragua','la fragua #6030','veracruz','veracruz','91830'); INSERT INTO Branch( branch_id, branch_name, branch_address, branch_city,branch_state,branch_zip) VALUES(915,'marti','marti #7030','veracruz','veracruz','91840'); INSERT INTO Branch( branch_id, branch_name, branch_address, branch_city,branch_state,branch_zip) VALUES(916,'americas','americas #1110','veracruz','veracruz','91850'); INSERT INTO Branch( branch_id, branch_name, branch_address, branch_city,branch_state,branch_zip) VALUES(917,'5 de mayo','5 de mayo #220','veracruz','veracruz','91860'); INSERT INTO Branch( branch_id, branch_name, branch_address, branch_city,branch_state,branch_zip) VALUES(918,'hidalgo','hidalgo #330','veracruz','veracruz','91870');