We have a stored procedure which we use to import the data in Excel using following vba
'With ActiveSheet.QueryTables.Add(Connection:=Array(ConString1), Destination:=Range("A1"))
.CommandType = xlCmdSql
.CommandText = IpSQLCommand
.FieldNames = True
.RowNumbers = False
.Refresh BackgroundQuery:=False
'End With
This has been working fine.
Recently we added few more fields to the output of Stored Procedure.
In the SQL studio all the fields shows up but in excel all the new fields are missing.