第六章 銀行ATM訪問款機系統初始化

2021-10-22 14:18:50 字數 3201 閱讀 4015

create database `db_bank`;

# 客戶資訊

create table `client`(

`nameid` int comment '顧客編號' auto_increment primary key not null,

`name` varchar(10) comment '開戶名稱' not null,

`id_number` varchar(18) comment '身份證號',

`phone` varchar(11) comment '聯絡**',

`address` varchar(20) comment '居住位址'

);# 銀行卡資訊

create table `account`(

`card_number` varchar(16) comment '卡號' not null primary key,

`nameid` int comment '顧客編號' not null,

foreign key(`nameid`) references client(`nameid`),

`password` varchar(20) comment '密碼',

`currency_id` int comment '貨幣種類編號'not null,

foreign key(`currency_id`) references currency_type(`currency_id`),

`deposit_type` varchar(20) comment '存款型別' not null,

`open_date` timestamp comment '開戶日期' not null,

`initial_deposit` decimal comment '開戶金額',

`balance` decimal comment '餘額',

`report` int(1) comment '是否掛失' default 0

);# 貨幣型別

create table `currency_type`(

`currency_id` int comment '貨幣種類號' not null primary key,

`currency_name` varchar(20) comment '貨幣種類名稱'

);# 交易資訊

create table `deal_message`(

`id_number` varchar(16) comment '卡號' not null,

foreign key(`id_number`) references account(`card_number`),

`deal_data` timestamp comment '交易日期' not null,

`deal_money` decimal comment '交易金額',

`note` varchar(50) comment '備註'

)insert into client values(1,'張三','189642198407089634','10080','記掛市');

insert into client values(2,'李四','152364197702341234','10040','大航州');

insert into client values(3,'王五','987654200010012233','10010','大俗州');

insert into client values(4,'趙六','123456200104045656','119','這將');

insert into client values(5,'鄭七','146529199405012648','120','傷嗨');

insert into currency_type values(1,'美元');

insert into currency_type values(2,'人民幣');

insert into currency_type values(3,'英鎊');

insert into currency_type values(4,'日元');

insert into currency_type values(5,'義大利里拉');

insert into currency_type values(6,'瑞士法郎');

insert into currency_type values(7,'荷蘭盾');

insert into currency_type values(8,'比利時法郎');

insert into account values('1562384923486512',1,'123456',2,'定期存款','2021-01-05',3000,300,0);

insert into account values('1562348953152463',3,'888888',4,'活期存款','2020-10-01',300000,26000,0);

insert into account values('1562315624895655',2,'471825',1,'活期存款','2009-02-25',2000,1500,1);

insert into account values('1562314562548759',5,'123456',7,'定期存款','2021-02-05',300.5,200.6,1);

insert into account values('1562345865977555',4,'123456',6,'活期存款','2019-08-05',400,350,0);

insert into deal_message values('1562384923486512','2021-03-08',200,'');

insert into deal_message values('1562348953152463','2020-02-12',200,'casdca');

insert into deal_message values('1562315624895655','2019-01-18',200,'vzxcvzcdad');

insert into deal_message values('1562345865977555','2018-03-03',200,'vsdfvadcasd');

insert into deal_message values('1562314562548759','2020-01-07',200,'vdssdcsadcadcda');

第六章 事件系統

2019 9 12事件 乙個事件會有多個事件型別處理事件的方法 1 重新實現事件處理函式,只能用來處理特定部件的特定事件 2 重新實現notify函式,一次只能處理乙個事件 4 重新實現event函式 5 在物件上安裝事件過濾器事件傳遞 exec函式使應用程式進入事件迴圈 qevent子類表示 傳遞...

第六章 訪問許可權控制

1.包訪問許可權 預設情況下通常是包訪問許可權,沒有任何關鍵字,有時也可以表示成friendly。2.其他包內的成員如果想要訪問這個包的成員,有如下的方式 a 使該成員成為public b 放置在同乙個包內 c 通過繼承,既可以訪問pubic也可以訪問protected成員 d 提供訪問器和變異器方...

第六章 系統匯流排

6.3 pci 匯流排 知識點 1 pci匯流排的系統結構以及pci匯流排的主要特點。2 pci基本訊號的定義以及pci交易過程中pci訊號的作用。3 pci配置的作用 如何實現pci配置。課程主體 pci 匯流排簡介 pci 匯流排訊號 pci isa 橋的訊號互動 pci 匯流排交換 pci 匯...