MS SQL Server
  Home arrow MS SQL Server arrow Page 5 - XML and the SQL 2000 Server part 3: XML Da...
ASP Free Forums 
.NET  
ASP  
ASP Code  
ASP.NET  
ASP.NET Code  
BrainDump  
C#  
Code Examples  
Database  
Database Code  
IIS  
Microsoft Access  
MS SQL Server  
Visual Basic.NET  
Windows Scripting  
Windows Security  
XML  
ASP Web Hosting  
ASP.NET Web Hosting 
Dedicated Servers 
Moblin 
JMSL Numerical Library 
Windows Web Hosting
 
IBM® developerWorks 
Sun Developer Network 
Weekly Newsletter
 
Developer Updates  
Free Website Content 
 RSS  Articles
 RSS  Forums
 RSS  All Feeds
Write For Us Get Paid 
Request Media Kit
Contact Us 
Site Map 
Privacy Policy 
Support 
 USERNAME
 
 PASSWORD
 
 
  >>> SIGN UP!  
  Lost Password? 
MS SQL SERVER

XML and the SQL 2000 Server part 3: XML Data with XPath Queries
By: Jayaram Krishnaswamy
  • Search For More Articles!
  • Disclaimer
  • Author Terms
  • Rating: 3 stars3 stars3 stars3 stars3 stars / 12
    2005-05-25

    Table of Contents:
  • XML and the SQL 2000 Server part 3: XML Data with XPath Queries
  • Xpath Queries
  • XDR Schema and XML View Mapper
  • Adding an SQL Module
  • Generating and Mapping an XDR Schema
  • Testing an Xpath Query Using the Internal Tester
  • Exporting Schema and Query in URL
  • Xpath Query With a Template File

  • Rate this Article: Poor Best 
      ADD THIS ARTICLE TO:
      Del.ici.ous Digg
      Blink Simpy
      Google Spurl
      Y! MyWeb Furl
    Email Me Similar Content When Posted
    Add Developer Shed Article Feed To Your Site
    Email Article To Friend
    Print Version Of Article
    PDF Version Of Article
     
     
    ADVERTISEMENT


    XML and the SQL 2000 Server part 3: XML Data with XPath Queries - Generating and Mapping an XDR Schema


    (Page 5 of 8 )

    Generating an XDR Schema

    Now going to the main menu and clicking on Tools->Utilities->Generate XDR Module will automatically generate an XDR schema, and will be added to the XDR Modulesfolder in the Project explorer as shown in the picture that follows with the extension .smx.

    Mapping Schema

    Now drag and drop the XDR schema into the right panel in the Map Editor. This creates an untitled Map in the Map Module in the project explorer with the extension .smm, an internal format type used by Microsoft[which includes .smt and .smx discussed earlier].

    By expanding all the nodes you can verify the type of mapping that is made. If you right click any of the connecting links between the SQL schema and the XDR you will bring up a menu item from which you may choose to carry out a number of things. The broken lines represent what is called the implicit mappings. It is possible to make an explicit mapping by keeping the mouse on the SQL object and draw a line[called the mapping line] to the XDR element. Any forbidden mappings [that are not allowed by Xpath queries] that you may attempt will be notified by a message with a warning icon.

    For example, an explicit connection was made from NumID in the SQL's nums table to the numid in the XDR's Color elements numid attribute, and this brings up the XML View Mapper Path finder as shown and if accepted, this will create an explicit relationship as shown in the picture that follows. Explicit relationships may be deleted and edited. The settings for Map Editor, Mapping Format, and Mapping Filter can be found in Tools->Options and the information on the mapping lines is stored in the Map Modules.

    The XDR Schema can be edited using a text editor which can accessed by right clicking on a mapping line and choosing the XDR Editor. To close this window you may use the Update Project and Close from the File Menu's drop down list.

    More MS SQL Server Articles
    More By Jayaram Krishnaswamy


     

    MS SQL SERVER ARTICLES

    - Completing the Introduction to Transact-SQL
    - A Brief Introduction to Transact-SQL
    - Lookups and Blocking Bad Data
    - Field Validation Rules for Blocking Bad Data
    - Using Masks to Block Bad Data
    - Blocking Bad Data
    - Using @@ROWCOUNT and TABLE Variables for Dat...
    - How to Use Variables, IF and CASE in Databas...
    - Creating Important Aspects of Notification S...
    - Working wth Variables in Database Interactio...
    - Delving Deeper into Notification Services
    - Notification Services
    - Building a Multi-table Report with SQL 2005 ...
    - A Secure Way of Building Connection Strings
    - Transferring a Database Using the SSIS Desig...





    © 2003-2008 by Developer Shed. All rights reserved. DS Cluster 4 hosted by Hostway