This should be a fairly straightforward question, but I haven\'t been able to find a solid answer online. I\'m trying to insert multiple rows into the same table, but with o
Since MS SQLServer 2005 supports XML the best method I would suggest is a STORED PROCEDURE with an input parameter of XML type. If you are working with .NET you can easily convert the DataSet to xml string using ds.GetXml() method and can be sent to the SP
CREATE PROCEDURE [dbo].[insertLocation](@XML XML=NULL)
AS
BEGIN
INSERT INTO [dbo].[TheLocations]
( [Name], [Location] )
SELECT
XTab.value('Name[1]','nvarchar(100)') AS[Name],
XTab.value('Location[1]','nvarchar(200)') AS[Location]
FROM @XML.nodes('TheLocations') XTab([XTab])
END