I've tried
select top 1 * from tbl
select top(1) * from tbl
select * from tbl limit 1
Nothing worked.
Does SQL Server Compact Edition support getting the top x rows?
I've tried
select top 1 * from tbl
select top(1) * from tbl
select * from tbl limit 1
Nothing worked.
Does SQL Server Compact Edition support getting the top x rows?
Yes it does, and your second syntax should be correct. What happens when you try it?
However, the keyword was added in version 3.5, so if you are using an earlier version, then the answer is no it doesn't. Sorry.
Docs from MSDN seems to indicate it should work.
http://msdn.microsoft.com/en-us/library/bb686896.aspx
Maybe post more of your script? Do you do anything else in there.
If your SQL CE hosed VS there is a Visual Studio Magazine post that talks about how to reinstall it correctly.
It is not fun, but it does work.