Command Text on data connection in 2010

Ben

New Member
Joined
May 23, 2002
Messages
37
Hi,
I have the following command text set in a connection to SQL server 2008. It works fine in Excel 2003, 2007, but not in 2010. Any ideas?

If I remove the where clause the connection works and retrieves prior year data as well as this one. But with the where clause it falls down in MS Excel 2010

"CALL_LINES"."dbo"."CORP_PROV_CEASE_LINES"
where week_end_date >{ts '2011-04-01 00:00:00'}
 

Excel Facts

Links? Where??
If Excel says you have links but you can't find them, go to Formulas, Name Manager. Look for old links to dead workbooks & delete.
It doesn't connect and bring back the data from the table.

I have solved it, I changed the command type from table to SQL and changed the command text to

select*
From
"CALL_LINES"."dbo"."CORP_PROV_CEASE_LINES"
where week_end_date >{ts '2011-04-01 00:00:00'}
 
Upvote 0
Ah, I assumed you'd just left out the SELECT bits as that shouldn't technically work at all otherwise, in any version! I guess the older ones are more forgiving.
 
Upvote 0

Forum statistics

Threads
1,224,517
Messages
6,179,234
Members
452,898
Latest member
Capolavoro009

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top