Reputation: 21252
I want to consume a .NET web-service that will accept SQL statement, for example: select * from my_table order by name
and will return that dataset to my Delphi ClientDataSet
/ disconnected TADODataSet
, and will display the result in the TDBGrid.
Part 2) After I update a single record I want to be able to update the .NET dataset via a webservice.
How can I do that? (Code Please)
Upvotes: 2
Views: 1430
Reputation: 11060
1) .Net datasets uses XML to transfer it's data, so you can read them as XML then convert them to Delphi Dataset, Look at these articles
Use ADO.NET Datasets in Delphi
Working with .NET data in Delphi
2) As I understand you will using Web services, so it will be better to add an update method to your service and call it to update the data.
One note, IMO, sending raw SQL to web services as the way you would like to use is a bad design, I prefer you to do define your business logic as group of methods, then call them as your application needs.
Also you can use Delphi Prism for more easier and better .Net integration
Upvotes: 2