Link to home
Start Free TrialLog in
Avatar of mynetquestions
mynetquestions

asked on

WCF Service to load data into the SQL Table

Hi,

I have an xml with the name "events.xml". This file need to be send as a parameter to wcf service. The respective data should be loaded into the multiple tables in the SQL server. (Table definitins in the file "events.sql")

The following is the requirement:

1. Address1, Address2, City, State and zip should be added into the "Event" table from the XML if it doesn't exist
2. Label should be mapped to Description, Lat to Latitude,  Lng to Longitude in the "Location" table for the Event Address (LocationType value is always "event")
3. scheduletype value is "event schedule"  and Description value is "event description" always in the "Schedule" table for the event addresss
4.Subject value is "Schedule subject", Label should be mapped to "Place", <date> values should be mapped to "Startdatetime" in the "ScheduleItem" table.
5.Service should return the count of new records created and count of existing records in each table.

I need help in writing WCF service. Can someone help me on this?
Events.xml
events.sql
Avatar of David Johnson, CD
David Johnson, CD
Flag of Canada image

WCF will send or receive data and is not the correct method for what you want to do with an existing .xml file  one would typically use SSIS to do what you want.
Avatar of mynetquestions
mynetquestions

ASKER

Hi David,

Basic intention to write a WCF service for the above requirement is, we want to implement one windows application to end user by consuming the above service when they load XML file.

I don't have any SSIS knowledge. Can you please help me and provide the steps to create SSIS package for the above requirement?
Windows Communication Foundation (WCF) is a framework for building service-oriented applications. Using WCF, you can send data as asynchronous messages from one service endpoint to another. A service endpoint can be part of a continuously available service hosted by IIS, or it can be a service hosted in an application.http://bit.ly/1IDLCVD
What you want is to create a WPF (Windows Presentation Foundation and you can take the xaml and code behind from it and put it in a web application
ASKER CERTIFIED SOLUTION
Avatar of Mlanda T
Mlanda T
Flag of South Africa image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Hi MlandaT,

Thanks for your solution. I would try it and let you know my experience.