Thursday, November 07, 2013

.NET User Group: WCF Data Services vs ASP.NET Web API

Presentation slides and code downloads:

Responses to some of the Questions

a) How do I issue PUT, POST or DELETE command?

This cannot be done directly using URL but can be done using Fiddler provided the HTTP verbs are allowed in the website (which can be configured in IIS)

Possible URI conventions:

b) Can WCF Data Services can be used without Entity Framework?

WCF Data Services is tightly coupled with Entity Framework. That's why it is quick and easy to generate the service. Still you can use WCF Data Services without entity framework with custom provider which will defeat the purpose (Quick and easy).

c) Is it possible to add the WCF Data Service as a Service Reference in other .NET project types?

Yes, this can be done as it is a typical Service (.svc) file.

Sunday, November 03, 2013

Dropping a Temporary table in SQL SERVER


"[OLE DB Destination [48]] Error: The input "OLE DB Destination Input" (61) cannot be set to redirect on error using a connection in a transaction


This issue raises if you try to use TransactionOption Required in SSIS while you have error rows to redirect between an OLE DB Source and an OLE DB Destination.


Instead try using a 3 Execute SQL tasks in the Control Flow with the first one before the data flow task with SQLStatement BEGIN TRANSACTION.

Put the rest of the 2 Execute SQL tasks in the Control Flow below the Data Flow Task with the precedence Constraint set for one as 'Failure' with the SQLStatement ROLLBACK TRANSACTION and the other one with the precedence Constraint set as 'Success' with the SQLStatement COMMIT TRANSACTION

Note: Also make sure to set the RetainSameConnection property on the appropriate ConnectionManager to True.