How to avoid the alphabetic order of the columns returned when selected from a SQL linked server.
-
Hi, I created a SQL Linked server for excel file. I am using that Linked server to Import the data from Excel files.When selecting the reords from this linked server , it returns the data in alphabetical order. But I want the same order of columns which is in Excel file. for selecting the records i am using tis Query: select * from ExcelImport...Test$ where, ExcelImport is Linked server name and Test$ is the sheet in the excel file. Please help. kalam.
-
Hi, I created a SQL Linked server for excel file. I am using that Linked server to Import the data from Excel files.When selecting the reords from this linked server , it returns the data in alphabetical order. But I want the same order of columns which is in Excel file. for selecting the records i am using tis Query: select * from ExcelImport...Test$ where, ExcelImport is Linked server name and Test$ is the sheet in the excel file. Please help. kalam.
Can you not provide the named columns in the select statement: e.g. Select cola, othercolumnname from excelimport