To return a dataset to a web service or not?

Is there a best practice for returning (or NOT returning datasets) from .NET web services? One camp says that we should facilitate interaction and use XML schemas to determine the payload of a web service, another camp says that we should return datasets because it is simple in Visual Studio and faster to do the work.

Some arguments in the anti-dataset camp:

  • Datasets are not compatible with WSI
  • Datasets are apparently rarely supported by third-party software.

Some arguments in the pro-dataset camp:

  • They are very convenient and fast in Visual Studio.
  • We (my company) are developing only in .NET, so interoperability is not a problem.
  • Client-side datasets have usability benefits.
+5
source share
3 answers

Use datasets? I would say a thousand times not. They are not compatible with other tools (as you mentioned). Of course, your only consumers now are .NET, but things can change quickly, and it's nice to be prepared.

See XML Files for some reading.

, , WCF. , . , .NET, TCP . , - , -, Java- () . . WCF -.

+3

, , , , .

API -, . , API .

Blackberry. -, , .

, , , .NET, .

+1

( ). , , .NET. - , , , .

DataSets also breaks down ideas for developing a managed domain and separating layers and is therefore less attractive because they were in the beginning. I use them only for demos that should be quick and dirty;)

If you really need a “simple” development method (in the IDE) and still comply with all standards, consider creating your services using WCF.

0
source

All Articles