I can "Select [TimeStamp] from RawData_SV... TimeStamp is column# 450... So, I can vba sql to get any combination of columns I want without linking anything. the 255 limit does not effect me (as long as I get <256 columns). Say, I want to get column 2, 260, 400, 450, I can get it with sql. So, what is the SQL to write to a local table and not to the sql server? The code below connects, executes. I want to an an INTO to send the recordset to a local table
Code:
Dim rs As New ADODB.Recordset
Dim cn As New ADODB.Connection
cn.Provider = "sqloledb.1"cn.Properties("Data Source").Value = "xxxxxxxxcom"
cn.Properties("Initial Catalog").Value = "IDB"
cn.Properties("Integrated Security").Value = "SSPI"
cn.Open
sql_txt = "select [TimeStamp] from [Raw_Data_SV]"
Set rs = cn.Execute(sql_txt)