将数据从一个表插入同一数据库的另一表后插入数据 [英] insert data after insert it from one table to another table in same database

查看:43
本文介绍了将数据从一个表插入同一数据库的另一表后插入数据的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

plz我需要将数据从减法表插入到支付表后

plz i need to insert data after it from substraction table to payment table

推荐答案

使用SQL触发器.
请先自己尝试一下,然后再问问题,以防万一您遇到任何错误.
在网上了解有关SQl触发器的更多信息.
Use SQL Trigger.
Please try it yourself first then asked question in case if you get any error.
Learn more about SQl trigger on the net.


您好,我认为您想将数据从一个表插入到第二个表,以供查询以下使用:

插入到TABLE1中从TABLE2中选择*

如果列名更改,则

插入到TABLE1中(金额)从TABLE2中选择金额
Hi, I think that you want to insert data from one table to 2nd table for this use below query:

Insert into TABLE1 Select * from TABLE2

If column name are change then

Insert into TABLE1(Amount) Select Amount from TABLE2


这篇关于将数据从一个表插入同一数据库的另一表后插入数据的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆