Append Values in Column from Table to Table In Kusto Control Command

34 Views Asked by At

If I have table A that has a column of Student Id, and I have table B that also has Student Id Column, what's the control command that to copy all values of Student Id from Table A to Table B?

2

There are 2 best solutions below

0
Werner On BEST ANSWER
.set student2 <| print StudentID = "12345", StudentAddress = "MyLane, Mycity"

.set student1 <| print StudentID = "12345", StudentName = "John"

.set   tmp <| student1 | join kind=inner student2 on StudentID | project-away StudentID1

.drop table student1

.set student1 <| tmp

.drop table tmp
0
Balaji On

To Append values from TableA to TableB in kusto you can use .set-or-append, it will update TableB with the data present in TableA as shown in the below query:

Data Stored in TableA: enter image description here

Data stored in TableB: enter image description here

.set-or-append TableB <| TableA

Output: enter image description here

For more information click this link.