I have a data in the following format :
ID Vendor Name Company Name
1 VendorA CompanyA
2 VendorB CompanyB
3 VendorC CompanyC
I want in the following format
ID CompanyDetails
1 CompanyA
1 VendorA
2 CompanyB
2 VendorB
3 CompanyC
3 Vendor C
i have used Union all but did not work , please help me write an sql script for this
thank you