I have a macro that, when run, performs the following operations:
a) Empties out an existing table
b) Uses Application.ImportXML to pull in new data from an XML file
c) Uses the following SQL to add a new column
DoCmd.RunSQL "ALTER TABLE sampling ADD COLUMN PartStep TEXT;"
d) Here's where I'm stuck. I now want to popuate the new column PartStep by concatenating the existing columns Part and Step from the data I just imported.
e) I then want to make column PartStep into the primary key.
Can anyone please help? How do I use VBA to perform d&e? Thank you in advance.