Presentation is loading. Please wait.

Presentation is loading. Please wait.

Webmasters’ Guild Workgroup Friday, April 2, 2010 Welcome These presentation slides will be available on the NYS Forum Web site at

Similar presentations


Presentation on theme: "Webmasters’ Guild Workgroup Friday, April 2, 2010 Welcome These presentation slides will be available on the NYS Forum Web site at"— Presentation transcript:

1 Webmasters’ Guild Workgroup Friday, April 2, 2010 Welcome These presentation slides will be available on the NYS Forum Web site at www.nysforum.org http://www.nysforum.org/committees/webmastersguild/resources.aspx

2 Webmasters’ Guild Workgroup Friday, April 2, 2010 Agenda Opening Remarks (5 mins) OCIO/OFT Update (5 mins) XML Databases and XQuery (30 mins) Brainstorming Planning Session (60 mins)

3 Webmasters’ Guild Workgroup Friday, April 2, 2010 XML Databases and XQuery A Brief Introduction Jim Costello

4 Webmasters’ Guild Workgroup Friday, April 2, 2010 Components of XML XML - encoding documents electronically XSL - transforming and rendering XML documents XPath - addressing the parts of an XML document XML Database – storing collections of XML data XQuery - querying collections of XML data SQL/XML - querying XML within SQL XForms - interfacing with XML data XRX - XForms-REST-XML Database (All XML)

5 Webmasters’ Guild Workgroup Friday, April 2, 2010 Common Uses of XML Data exchange - XML enables platform-independent data exchange among applications. Web content management - usually implemented as a Web application, for creating and managing HTML content. Content is frequently, but not universally, stored as XML. RSS - a simple XML format used to syndicate headlines.

6 Webmasters’ Guild Workgroup Friday, April 2, 2010 Data and Databases Relational vs. XML Relational no hierarchy or significant order; based on two-dimensional tables. Used for storing and querying data. Data is stored in columns and rows with key fields that join data together from separate tables; schema necessary. XML hierarchical and sequential; based on trees in which order matters. Used for exchanging and displaying data. Data is stored as XML documents; can be highly structured, semi-structured, or unstructured; schema not necessary.

7 Webmasters’ Guild Workgroup Friday, April 2, 2010 Relational Database (tables, columns, rows, keys)

8 Webmasters’ Guild Workgroup Friday, April 2, 2010 XML Database (collections, files)

9 Webmasters’ Guild Workgroup Friday, April 2, 2010 From Web Form to Relational Database “shredding”

10 Webmasters’ Guild Workgroup Friday, April 2, 2010 From Web Form to XML Database “as is”

11 Webmasters’ Guild Workgroup Friday, April 2, 2010 The Real Difference "XML is by definition self-describing data. Build the database around that structure not the other way around. The implementation is far from being that simplistic. This basic concept however – leverage XML’s self-describing and hierarchical nature to manage it – is the very foundation of an XML database." (from http://bigmenoncontent.com/2009/05/28/xdb- matters/ )http://bigmenoncontent.com/2009/05/28/xdb- matters/

12 Webmasters’ Guild Workgroup Friday, April 2, 2010 When and Why to Use an XML Database Got XML? (If you have more than a handful of XML documents to store, consider using an XML database.) Storing and querying document-centric XML, integrating data, and storing and querying semi-structured data. Handling rapidly evolving schemas, working with very large documents, querying hierarchical data, and running Web sites (content management).

13 Webmasters’ Guild Workgroup Friday, April 2, 2010 Two Immediate Benefits By storing XML data as XML in XML database: Simplified storage New query capabilities

14 Webmasters’ Guild Workgroup Friday, April 2, 2010 XQuery FLWOR Syntax: For – iterates through an input sequence Let – declares a variable and gives it a value Where – filters the selection Order by – sorts Return – defines the result Somewhat similar to Select statement in SQL: SELECT * FROM locationsTable WHERE city = “Albany” ORDER BY zip;

15 Webmasters’ Guild Workgroup Friday, April 2, 2010 Retrieving Data from Database Perform query to select all registrations for a specific course and sort them by date Using XML for Web Site Management Main Office 2010-01-21 08:30:00 12:30:00 James Costello CTG 765-4321 jjj@jj.com Using XML for Web Site Management Microknowledge 2010-06-04 08:30:00 16:30:00 Liz Weaver Advocates for Homeless 518-777-1234 liz.weaver@afh.org Using XML for Web Site Management Microknowledge 2010-06-04 08:30:00 16:30:00 Franklin Parker Advocates for Homeless 518-777-4321 franklin.parker@afg.org Using XML for Web Site Management 00034 2010-08-11 08:30:00 12:30:00 James Costello CTG 765-4321 jjj@jj.com

16 Webmasters’ Guild Workgroup Friday, April 2, 2010 Simple FLWOR Statement xquery version "1.0"; for $registrations in collection("classRegistrations")/classRegistrations/class let $date := $registrations/date/text() where $registrations/className = "Using XML for Web Site Management" order by $date return $registrations

17 Webmasters’ Guild Workgroup Friday, April 2, 2010 Similar Statement in SQL SELECT course.courseName, class.location, class.date, class.timeStart, class.timeEnd, student.firstName, student.lastName, student.organization, student.phone, student.email FROM course,class,student,classStudent WHERE course.courseName="Using XML for Web Site Management" and course.courseID = class.courseID and classStudent.classID = class.classID and classStudent.studentID = student.studentID ORDER BY class.date;

18 Webmasters’ Guild Workgroup Friday, April 2, 2010 Similar Statement in XSL/XPath

19 Webmasters’ Guild Workgroup Friday, April 2, 2010 New Query Capability Query Create a personalized RSS feed based on keyword(s) that an individual wants to track within CTG’s Website. How? Since all content on website is stored in XML database, it is all available to query. An XForms interface would enable visitors to submit their own terms of interest for building a personalized RSS.

20 Webmasters’ Guild Workgroup Friday, April 2, 2010 New Query Results http://www.ctg.albany.edu/about/fulltextsearchRSS?param1=collaboration

21 Webmasters’ Guild Workgroup Friday, April 2, 2010 New Query Capability Query Create a list of CTG publications grouped by main author. How? Since all content on website is stored in XML database, individual documents can be queried at the node level and combined, grouped and sorted into results that are difficult if not impossible to achieve without XQuery.

22 Webmasters’ Guild Workgroup Friday, April 2, 2010 New Query Results http://www.ctg.albany.edu/publications/authorsList?sub=working

23 Webmasters’ Guild Workgroup Friday, April 2, 2010 Articles 1.XML Databases - The Business Case http://www.cfoster.net/articles/xmldb-business-case/ http://www.cfoster.net/articles/xmldb-business-case/ 2.Introduction to Native XML Databases http://www.xml.com/pub/a/2001/10/31/nativexmldb.html http://www.xml.com/pub/a/2001/10/31/nativexmldb.html 3.Ronald Bourret, Consulting, writing, and research in XML and databases http://www.rpbourret.com/xml/ http://www.rpbourret.com/xml/ 4.Going Native: Making the Case for XML Databases http://www.xml.com/pub/a/2005/03/30/native.html http://www.xml.com/pub/a/2005/03/30/native.html 5.A comparison of XML-enabled and native XML data management techniques http://xml.sys-con.com/node/104980?page=0,0 http://xml.sys-con.com/node/104980?page=0,0 6.Feature Comparison: EMC Documentum xDB vs. Oracle XML DB & IBM DB2 pureXML https://community.emc.com/docs/DOC-2999 https://community.emc.com/docs/DOC-2999 7.XRX: Simple, Elegant, Disruptive http://www.oreillynet.com/xml/blog/2008/05/xrx_a_simple_elegant_disruptiv_1.html http://www.oreillynet.com/xml/blog/2008/05/xrx_a_simple_elegant_disruptiv_1.html

24 Webmasters’ Guild Workgroup Friday, April 2, 2010 Tutorials 1.Michael Kay’s XQuery Tutorials on Stylus Studio site http://www.stylusstudio.com/xquery_primer.html http://www.stylusstudio.com/xquery_primer.html 2.XQuery Wikibook http://en.wikibooks.org/wiki/XQuery http://en.wikibooks.org/wiki/XQuery 3.XForms Wikibook http://en.wikibooks.org/wiki/XForms http://en.wikibooks.org/wiki/XForms 4.XRX Wikibook http://en.wikibooks.org/wiki/XRX http://en.wikibooks.org/wiki/XRX 5.w3Schools Tutorial http://www.w3schools.com/xquery/default.asp http://www.w3schools.com/xquery/default.asp 6.Various XQuery Links http://delicious.com/jimcost/xquery http://delicious.com/jimcost/xquery

25 Webmasters’ Guild Workgroup Friday, April 2, 2010 Linkedin Groups 1.eXist-db Open Source Native XML Database 2.Gov 2.0 XQuery, XForms and RESTful Services 3.XForms 4.XML and Related Technologies Network 5.XML Databases 6.XML-in-Practice 7.XQuery Network 8.XRX Web Application Architecture

26 Webmasters’ Guild Workgroup Friday, April 2, 2010 Contact Jim Costello Center for Technology in Government jcostello@ctg.albany.edu twitter.com/jtcostello http://delicious.com/jimcost/xquery 518-442-3812

27 Webmasters’ Guild Workgroup Friday, April 2, 2010 Open Forum Brainstorming Planning Session URL Shortener for NYS Mobile Apps Development group Link Management –Approaches and software (Dreamweaver, Xenu, Siteimprove, Firefox Developer Kit) Credit Card Payment Processing –Home-grown solutions? Outsourcing? Paypal?

28 Webmasters’ Guild Workgroup Friday, April 2, 2010 Thank You See you next month Friday May 7, 2010 9:00 am to Noon NYS Museum Huxley Theatre Slides available at: http://www.nysforum.org/committees/webmastersguild/resources.aspx

29 Webmasters’ Guild Workgroup Friday, April 2, 2010 Similar Statement in SQL SELECT course.courseName, class.location, class.date, class.timeStart, class.timeEnd, student.firstName, student.lastName, student.organization, student.phone, student.email FROM student INNER JOIN (course INNER JOIN (class INNER JOIN classStudent ON class.classID = classStudent.classID) ON (course.courseID = class.courseID) AND (course.ID = classStudent.ID)) ON (student.studentID = classStudent.studentID) AND (student.ID = class.ID) WHERE (((course.courseName)="Using XML for Web Site Management")) ORDER BY class.date;


Download ppt "Webmasters’ Guild Workgroup Friday, April 2, 2010 Welcome These presentation slides will be available on the NYS Forum Web site at"

Similar presentations


Ads by Google