Dear Community,
I'm impressed by the powerful database feed and the way how to execute queries. But I'm having issues with the RANK() OVER (PARTITION BY) statement, which does not work in the database feed query field.
The error message:
The following error occurred when running SQL query "SELECT STKGRP, AMT_LCY Rank()OVER(Partition by STKGRP Order by AMT_LCY DESC) as ‘Ranking’ FROM dbo_SALEINVOICE" on database "Access": [Microsoft][ODBC Microsoft Access Driver] Syntax error (missing operator) in query expression 'AMT_LCY Rank()OVER(Partition by STKGRP Order by AMT_LCY DESC)'.
The underlying database is MS Access which again uses linked ODBC tables to gather the data from SQL Server 2005.
I haven't had any bigger problems with this setup so far, but this problem is really tough.
Here's a brief introduction into the RANK() OVER statement:
http://riteshshah.wordpress.com/2009/03/03/use-of-rank-and-partition-by-clause-in-sql-server-2005/
Thank you very much!