Hi everyone
I was wondering whether someone can help me with the following, I am just started to play around with importing data to excel worksheet via SQL connection but am stuck on getting the column headers for my imported data. I can successfully connect to the database and import the data however I am not sure about the code to give the columns the name from the database.
My code is below
As I mentioned the data is imported successfully but I need to name each Column. One of the columns in the SQl is called UID_Site and I need this to be called Site when is imported. This is my first column.
I hope this makes sense and any help is appreciate it
Thanks in advance
Bookmarks