 |
|
สอบถามหน่อยครับ การเปรียบเทียบข้อมูลใน Datatable ทั้ง 2 VB |
|
 |
|
|
 |
 |
|
ทำที่ Query ได้นะครับ ด้วยการ JOIN แล้วใช้ CASE WHEN ในการเปรียบเทียบครับ 
|
 |
 |
 |
 |
Date :
2018-07-16 13:05:16 |
By :
mr.win |
|
 |
 |
 |
 |
|
|
 |
 |
|
 |
 |
 |
|
|
 |
 |
|
ถ้าเอาแบบง่ายๆเลยก็ query ครับ
declare @temp1 table (
id_ int ,
name_ nvarchar (50)
)
declare @temp2 table(
id__ int,
name__ nvarchar (50)
)
insert into @temp1 values ('1','a')
insert into @temp1 values ('2','b')
insert into @temp1 values ('3','c')
insert into @temp1 values ('4','d')
insert into @temp1 values ('5','e')
insert into @temp1 values ('6','f')
insert into @temp1 values ('7','g')
insert into @temp2 values ('1','a')
insert into @temp2 values ('2','b')
insert into @temp2 values ('3','z')
insert into @temp2 values ('4','d')
insert into @temp2 values ('5','e')
insert into @temp2 values ('6','f')
insert into @temp2 values ('7','g')
select * from @temp1
intersect
select * from @temp2
|
 |
 |
 |
 |
Date :
2018-07-16 20:59:00 |
By :
adminliver |
|
 |
 |
 |
 |
|
|
 |
 |
|
 |
 |
|
|