Quick References
      ADO
      ASP
      CSS2
      HTML
      JavaScript
      Jet SQL
      VBScript
      WML
      WMLScript
      WSH
      XHTML
      XML DOM
      XSLT

Features
      Knowledge Base
      Tutorials

Partners
     ZVON.ORG
     XML
     Planet Source Code
     VisualBuilder
     Web Design
     Your HTML Source
     XML/XSLT Forums
     ASPAlliance
     Scripts
     
     Programmers Heaven
     Tek-Tips Forums
     Developer Fusion
     Code Project



SQL Server 2000, XML and XSL: The Ultimate Combination


Creating our sample database

On your SQL Server, open Enterprise Manager and create a new database named "myProducts". Then, using either Enterprise Manager or Query Analyzer, create the tables shown below:

(Note: catId, productId and descId are all auto-incrementing identity fields)

As you've probably guessed, we're using three tables to simulate a very simple product description database (let's assume we sell books). The diagram above shows the hierarchy of our data: categories listing products, listing their descriptions. Before we progress to the next step, we'll need to create some dummy data in our tables. To maximize productivity and minimize the length of this article, I've created a simple T-SQL script, which will populate our tables as needed. You can download it as part of the support material at the end of this article. The script will create 3 categories, 7 products and 7 descriptions.


 
  1 2 3 4 5
 
   
Copyright 1999-2005 by Infinite Software Solutions, Inc. All rights reserved.
Trademark Information
knoxville photographer
knoxville wedding photographer