How to store XML into SQL with store procedure?

Hi all,

I got this xml and I want to store it into SQL server (with SQLXML), I have a table with all the fields so I want to map the data in XML to all the fields in DB.
- Is store procedure the best way to do it? Are there any better way to do it?
- Do you have any similiar examples?
- Any good articles on the net that related to this topic?
Thanks a lot and happy new year!
Edwin
I am a newbie
-----------
<quote symbolstring="QMCI" datatype="equity" delaymin="15"
time="2003-09-12T14:43:05-0400">
<key>
<symbol>QMCI</symbol>
<exchange>OBB</exchange>
</key>
<equityinfo>
<longname><![CDATA[ Quotemedia Inc ]]></longname>
<shortname><![CDATA[ QMCI ]]></shortname>
</equityinfo>
<pricedata>
<last>0.400</last>
<change>0.000</change>
<changepercent>0.000</changepercent>
<tick>1</tick>
<open>0.410</open>
<high>0.430</high>
<low>0.395</low>
<prevclose>0.400</prevclose>
<bid>0.400</bid>
<ask>0.400</ask>
<bidsize>5000</bidsize>
<asksize>5000</asksize>
<tradevolume>46</tradevolume>
<sharevolume>348500</sharevolume>
</pricedata>
<fundamental>
<sharesoutstanding>57239204</sharesoutstanding>
<marketcap>22895682</marketcap>
<eps>-0.020</eps>
<week52high>0.430</week52high>
<week52low>0.040</week52low>
</fundamental>
</quote>
0
siumaibb
1/5/2005 1:27:47 AM
asp.net.xml-datasource 7181 articles. 0 followers. Follow

2 Replies
756 Views

Similar Articles

[PageSpeed] 4

Try using SQLXML 3.0 Bulk Load.
RED
0
red
1/5/2005 2:53:57 PM
Do a google on UPDATEGRAM, since you already said you are using SQLXML.  If you can't find the right answer, let me know.
Cristian Sturek
Principal SOA Architect
http://www.xwebservices.com
http://www.soahub.com
0
csturek
1/6/2005 10:49:09 PM
Reply:

Similar Artilces:

Passing an XML variable argument to a SQL Server 2005 Stored Procedure with an XML data type
Is it possible to pass an XML variable to a SQL Server 2005 Stored Procedure with the XML data type as it's receiving argument? I can get the SQL Server Procedure to work perfectly with XML passed to it from another Stored Procedure, but as soon as I define a Stored Procedure from within a datawindow to pass parameters to it, I get "Cannot create DataWindow" and "XML parse error occurred on line number 1, near the XML text "0"". Essentially, I want to use the XML string, built by data keyed by the client within a datawindow, to be loaded to a temp t...

Execute Stored Procedure with input xml and retrieving output xml
I created a stored procedure for MSSQL that returns a XML: {code} CREATE PROCEDURE [dbo].[SP_Processa_Dados] @XMLParamIN XML, @XMLParamOUT XML OUTPUT AS BEGIN SET NOCOUNT ON; SET @XMLParamOUT= @XMLParamIN; END {code} I want to use TADOStoredProc for input the Value the XML that and return that XML to give him treatment... How can i do that? "Helder Lopes" wrote in message news:680079@forums.embarcadero.com... >I created a stored procedure for MSSQL that returns a XML: > {code} > CREATE PROCEDURE [dbo].[SP_Processa_Dados] > @XMLParamI...

FOR XML and OPENXML using Oracle / using xml in ORACLE stored procedure
Hi, I need a help with respect to xml operations in ORACLE.For example, Need to send multiple rows at once into stored procedure.orNeed to  pass data (a single entity) to stored procedure as a xml from Data Layer ( Instead of individual params)In case of sql server, There is an approach like,     From Front End,   Serialize the entity collection or single entity as xml and send to the db.   Pass xml to stored procedure from Data Layer     sql server stored proc in turn,  &n...

SQL Stored Procedure Issue
This is the Stored Procedure below ->  SET QUOTED_IDENTIFIER ON GOSET ANSI_NULLS ON GO /****** Object:  Stored Procedure dbo.BPI_SearchArchivedBatches    Script Date: 5/18/2007 11:28:41 AM ******/if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[BPI_SearchArchivedBatches]') and OBJECTPROPERTY(id, N'IsProcedure') = 1)drop procedure [dbo].[BPI_SearchArchivedBatches]GO /****** Object:  Stored Procedure dbo.BPI_SearchArchivedBatches    Script Date: 4/3/2007 4:50:23 PM ******/ /****** Object:  Stored Proc...

SQL Stored Procedure to MySQL Stored Procedure Conversion
Hi, I am trying to convert a stored procedure written for sql to one that will work in mysql. I understand that I have to set the variables as IN , but I don't know what to do with the rest of the code. The following is the sql stored procedure that I am trying to convert to msql stored procedure: CREATE PROCEDURE Register_User (@userName Varchar(50), (@PassWord Varchar(50), (@FirstName Varchar(50), (@LastName Varchar(50) ) AS IF EXISTS(SELECT u_ID FROM User_ID Where u_UserName=@UserName) RETURN -1 ELSE INSERT User_ID( u_User...

Linq to SQL question: Store Procedure returns xml?
I have a stored procedure that returns XML as CREATE PROCEDURE [dbo].[sp_TestQueryXml]   @NameStartsWith nvarchar(255)AS   SELECT * FROM TableX WHERE [Name] LIKE @NameStartsWith + '%' for xml autoGO Is there a way to hook this up to a linq to sql method?blog.bodurov.com add the stored procedure to your datacontect (DBML) and a function will be created.  You can then access it as Dim db As New myDataContext Dim query = FROM foo in DB.TestQueryXML                 &nb...

XML/XSL -- Multiple Results from SQL Stored Procedures
I have several XML/XSL modules retrieving "FOR XML" data from SQLServer stored procedures.  I now have a single instance that has three subsections.  I can, of course, have the single stored proc return three resultsets.  These three sets have very different structure....and hence cannot simply be "UNION"ed in the stored proc....but joining these into one XML doc seems perfectly normal. My questions are:  What is the best way in DNN to retrieve all three resultsets (ExecuteReader appears only to grab the first)?  And secondly: Does anybody have sample code? Many th...

Bind XmlDataSourceControl to XML from SQL Server 2005 Stored Procedure
Hi, I have a Sql Server 2005 stored proc that has one in-parameter and returns one row/column with XML. Inside the StoredProc I have used the "FOR XML" statement. Now I like to bind a <asp:TreeView> control to the output. I know how to bind the TreeView to the XmlDataSouce if I have a XML file but is it possible to bind the output from the StoredProc to the XmlDataSouce? Thanks,Dirk I wonder whether the XmlDataSource can be bound to an output via Data element, but we can use a query to generate a xml file. For example, this procedure generates a xml file from a query, ac...

MS SQL stored procedures inside another stored procedure
Hi,  Do you know how to write stored procedures inside another stored procedure in MS SQL.   Create procedure spMyProc inputData varchar(50) AS  ----- some logical    procedure spMyProc inputInsideData varchar(10) AS    --- some logical   ---  go ------- What exactly are tou trying to do? ***********************Dinakar NethiLife is short. Enjoy it.*********************** Like Function, you can have one function inside another another function. Function1 () {    Function2() } How about store procedure ? spProc1 { &n...

sql count using stored procedure withing stored procedure
I have a stored procedure that among other things needs to get a total of hours worked. These hours are totaled by another stored procedure already. I would like to call the totaling stored procedure once for each user which required a loop sort of thing for each user name in a temporary table (already done) total = result from execute totaling stored procedure Can you help with this Thanks It would be easier if you can change the stored procedure into a function. Once you do that, the total can be calculated easily with something like thisSelect Sum(dbo.CalculateHours(User...

syntax of reading XML from SQL stored procedure using IE
I want to read output from SQL stored procedure from IE. I have some problem with syntax. When I use just one parametr, I can write: http://ales/InfoOffice2002?SQL=XMLMarketing+ahoj But I don't know how to write it with two parameters.Ales Ruzicka18 years old Czech student & cleaner :)interested in internet technologiesmyBlog...

How to convert Sql Server Stored Procedures into Oracle Stored Procedures
Hi All, I am migrating from sql server2000 to oracle. I have moved all table into oracle manually. Now I need to move stored procedure. I don't know how to convert sql server stored procedure into oracle stored procedure form. Is there any tool which will convert directly. Please some one help me. Thank you.    Hi there,Please use the tool bellow, which does the job you want. http://www.swissql.com/products/sqlserver-to-oracle/sql-server-to-oracle.html thanks sharp guy...

How to pass a XML data parameter to an SQL 2005 Stored Procedure
How to pass a XML data parameter to an SQL 2005 Stored Procedure I hope to insert a xml data into an typed xml column in SQL 2005. 1. I can run the Code 1 correctly. 2. I hope that I can pass a XML data parameter to an SQL 2005 Stored Procedure, So create the Code 2. but I get the error below:XQuery [cw_bookmark.Bookmark.modify()]: Only non-document nodes can be inserted. Found "xs:string ?". 3. I create the Code 3, but I get the error below:XQuery [cw_bookmark.Bookmark.modify()]: ',' or ')' expected  4. I create the Code 4, but I get the error below:XQuery: SQL type 'xml' is not...

inserting xml data in sql database using store procedure
 i want to write gridview data in Xml file and pass that xml file as input parameter tostore procedures and insert xml file data to sql database table.i dont how to write xml file and how to pass it to store procedurepl help me asap its urgent    "To handle XML from an xml data type column by using ADO.NET and the Microsoft .NET Framework you can use the standard behavior of the SqlCommand class. For example, an xml data type column and its values can be retrieved in the same way any SQL column is retrieved by using a SqlDataReader.However, if you want to work with the...

Web resources about - How to store XML into SQL with store procedure? - asp.net.xml-datasource

Invasiveness of surgical procedures - Wikipedia, the free encyclopedia
There are three main categories which describe the invasiveness of surgical procedures . These are: non-invasive procedures , minimally invasive ...

Procedure is more a snap than a snip
A QUEENSLAND doctor is bidding to set an unusual world record by performing the highest number of vasectomies in one day, with the help of fellow ...

Rushed cosmetic procedures a 'recipe for disaster'
&#8203;When Chanelle O'Hare went searching online for a deal on potential cosmetic procedures, she could not have imagined that what she ended ...

Jetstar procedures under investigation after planes took off too heavy
Jetstar's procedures for calculating the weight of its aircraft are under review by the Australian Transport Safety Bureau after two of its planes ...

NFL Announces Changes to Officiating Procedures for Playoffs - Bleacher Report
The NFL formally approved changes to its postseason officiating procedures to allow referees the opportunity to consult Vice President of Officiating ...

Will Paul Ryan Make His Mark As Speaker By Instituting Impeachment Procedures Against President Obama ...
Wisconsin Ayn Rand devotee Paul Ryan just started his new job as Speaker of the dysfunctional House Republicans. And he's already headed for ...

NFL security procedures in question after rappelling protesters
Two protesters with sophisticated gear disrupted the Panthers-Colts game in Charlotte Monday night, bringing into question security at the stadium ...

'Painless' dental cavity procedure regrows tooth enamel
... "cavity" a lot of people sweat thinking about painful injections and relentless drilling. But scientists in Britain have developed a new procedure ...

'Daily Show' Host Trevor Noah Hospitalized for Emergency Procedure
'Daily Show' Host Trevor Noah Hospitalized for Emergency Procedure

Why Are Web Login Security Procedures So #$*&!% Dumb And Obnoxious?
The geeks who design our websites talk a lot about user friendliness, but they often let an exaggerated security concerns get in the way of commonsense. ...

Resources last updated: 12/22/2015 8:39:43 AM