当前位置:网站首页>SQL SERVER on master-slave table trigger design
SQL SERVER on master-slave table trigger design
2022-08-05 07:54:00 【CSDN Q&A】
There are two two tables, A and B relationship is a master-slave table.
A table has two fields, date and number.
Table B has four fields of date and specification and number and quantity.
The number field of the two tables is an association relationship.
Currently A's data is triggered from other tables.Then add table B according to the data of table A.(It means that there is a load of goods in table A, and I want to slowly classify table B), and then the next step I need is to summarize the data in table B into table C by date and specification, and there must be two summaries,One label is injected into the library, and the other is labeled out of the library.
I have tried to write triggers in table B, but if table B adds a record, table C will add one, so it is unrealistic and can only be written in table A.
At present, I don't know if the data of table B is summarized in table A and inserted into table C, someone can give me some ideas on how to write it?
边栏推荐
猜你喜欢
随机推荐
TRACE32——通用寄存器查看与修改
环网冗余式CAN/光纤转换器 CAN总线转光纤转换器中继集线器hub光端机
2006年星座运势全解-射手
Flink Learning 12: DataStreaming API
An IP conflict is reported after installing the software on a dedicated computer terminal
强网杯2022 pwn 赛题解析——house_of_cat
学习机赛道加速:请“卷”产品,不要“卷”营销
在原有数据库基础上执行sql文件有则跳过没有则添加如何实现?
图片地址转为base64
数据库——概述
P1103 书本整理
Liunx教程超详细(完整)
存储过程编写经验和优化措施
2022.7.29好题选讲(计数专题)
Redis数据库学习
openSource 知:社区贡献
关于MP3文件中找不到TAG标签的问题
[instancetype type Objective-C]
TRACE32——Break
Qt writes custom controls: one of the text spotlight effects