I want to expose a service operation of a WCF Data service over FTP
I was wondering how to best approach this
I was thinking of writing a batch file, which will invoke the WCF dataservice, write the data returned by the service to a FTP location and grant access to the Client to that particular FTP location
Do you think this is a better idea?
You cannot do this. A WCF Data Service is always a REST-based HTTP service - and it's very interactive - you cannot achieve this on an FTP server.
If you want to expose and make available data on an FTP server, I would use your server-side code to produce that data set (by e.g. querying the data source), then wrap this up in an Excel sheet or whatever format is appropriate, and transfer that file onto the FTP server on the server-side.
Seems like it might be possible to expose a WCF method as an FTP endpoint:
The address defines where the service is located; this could be a
URL, an FTP address, or a network or local path. A binding defines the
way that you communicate with the service. WCF bindings provide a
versatile model for specifying a protocol such as HTTP or FTP, a
security mechanism such as Windows Authentication or user names and
passwords, and much more. A contract includes the operations that are
exposed by the WCF service class.
http://msdn.microsoft.com/en-us/library/bb907578.aspx
Some more info here http://social.msdn.microsoft.com/Forums/en-US/wcf/thread/5220693e-2366-44f7-b56d-35de73d18472#0c8160bc-d687-4e48-9ba9-000755284e43