Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
AskSQLTeam
Ask SQLTeam Question
0 Posts |
Posted - 2001-07-25 : 08:52:31
|
Fred writes "Hi SQLTeam,I need help in developing a SQL 2000 query that would request an XML document from a web server at http://MyRemoteSensor/data.xml and insert the XML content into a database.The xml document is as follows:<?xml version="1.0" standalone="yes"?><DEMO_CENTER_DOCUMENT> <ANALOG_POINTS> <ANALOG_INPUT> <VALUE>24.9443</VALUE> </ANALOG_INPUT> </ANALOG_POINTS></DEMO_CENTER_DOCUMENT> Each time this document is read from the server, the <VALUE> element is updated with a fresh value.I need have the SQL Server read the XML document and store the element <VALUE> into the database.Here are my questions?How can I get SQL Server 2000 to automatically do something periodically?How can I get the XML document from the web-server via http port 80 and insert the data value into the db, without using a middleware application written in VB, Java, etc?So far I have researched the use of IE browser and SQL 2000 and can write html, xml and xsl to select and display data from the database. I need help in getting the data from the remote server (using http) into the SQL DB.Any help will be appreciated.Thanks in advance for your consideration.Fred Hart" |
|
|
mensan
Starting Member
1 Post |
Posted - 2001-11-29 : 04:45:20
|
| Hello all,Can I ask a question? Our system is written to run in JDK1.2.2, Tomcat and Internet Information Server 5.0 and connects to Microsoft SQL Server 7.0 via JDBC. Is there an easy way to run a SQL query and receive results in the form of XML? |
 |
|
|
Merkin
Funky Drop Bear Fearing SQL Dude!
4970 Posts |
Posted - 2001-11-29 : 05:56:48
|
| Hi Yeah, you can put a FOR XML clause at the end of your select statement. You can have a look in books online for more details. Or if you post what your data looks like and the format you want to get it in we can help more.Damian |
 |
|
|
|
|
|