且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

如何将两个数据表合并到.net中的一个数据表中

更新时间:2023-02-09 21:59:34

是的,这是可能的。

创建第三个表有所有5列并用两个表填充数据。
yes it is possible.
Create third table have all 5 columns and populate the data with both the tables.


你需要合并两个数据库或两个表?


BTW你正在使用的数据库是什么?
you need to combine two databases or two tables ?

BTW what is the database that you are using ?


Hai

谢谢重播,


我正在使用MS SQL Server。我从数据库中获取数据,在我后面的代码中使用两个数据表进行两个存储过程。最后我需要将两个数据表合并为一个和我希望结果是pyarlally即。

datatable1 --10行x 2列

datatable2 --10行x 3列


结果表:---- 10r ows x 5列是否可能.....?


谢谢,

Aswath。
Hai
Thanks for Replay,

Im using MS SQL Server.Im getting data from Database,In code behind im using two datatables for two stored procedures.finally i need to combind two datatables to one and i want the result in pyarlally ie.
datatable1 --10 rows x 2columns
datatable2 --10 rows x 3 columns

result table:---- 10rows x 5 columns is it possible.....?

Thanks,
Aswath.