The module uses the creatino of tables by means of:

CREATE TABLE {XX} SELECT ....

This is not compatible with SQL Server.

I fixed it, patch provided.

I have also seen that, on the same file, there is a similar problem somewhere else but I have no time to fix.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Status: Needs review » Needs work

The last submitted patch, views_data_export_plugin_display_export.inc_.patch, failed testing.

david_garcia’s picture

Issue summary: View changes
Related issues: +#1364584: SQL Server support
ruloweb’s picture

@david_garcia thanks for your fix! it works ok for me too.

I created another version which creates the class views_data_export_plugin_query_sqlsrv_batched with the small fix. Notice that for pgsql there is a different CREATE TABLE implementation too, so the module maintainer created the views_data_export_plugin_query_pgsql_batched class to address that, maybe this is what you see has a different problem.

I also forced the query to run always $query->range(), because when the views has an order by clausule, it will throw:

The ORDER BY clause is invalid in views, inline functions, derived tables, subqueries, and common table expressions, unless TOP, OFFSET or FOR XML is also specified.

Thanks!

ruloweb’s picture

Status: Needs work » Needs review
sosyuki’s picture

@ruloweb thanks for your fix! it works ok for me.