PowerPoint presentation | free to download - id: 6c79d7-ODNiZ

<title> XML?XQuery ,????????? </title> - PowerPoint PPT Presentation

1 / 25
About This Presentation
Title:

<title> XML?XQuery ,????????? </title>

Description:

... Tamino XML NXD Software AG 1.X-Engine 2.Data Map 3.Tamino Manager 1.Tamino ... – PowerPoint PPT presentation

Number of Views:53
Avg rating:3.0/5.0
Slides: 26
Provided by: you125
Category:
Tags: xml | tamino | xquery

less

Transcript and Presenter's Notes

Title: <title> XML?XQuery ,????????? </title>


1
lttitlegtXML?XQuery ,?????????lt/titlegt
  • ltprofgt???lt/profgt
  • ltstud.gtD954020009 ???
  • D954020002 ???lt/stud.gt

2
Outline
  1. ??
  2. ????
  3. ???SQL??
  4. XML???????????
  5. ??

3
1.?? (1/4)
  • XML???
  • XML?HTML
  • ML??
  • HTML???
  • 1.????????
  • 2.???????
  • 3.?????????

4
1.?? (2/4)
  • XML?????

  lt?xml version"1.0" encoding"Big5" ?gt -
ltlibgt ltbookgt   lttitlegtXML???lt/titlegt  
ltauthorgtMarylt/authorgt   ltpricegt590lt/pricegt  
lt/bookgt - ltbookgt   lttitlegt??? 7-11 ????lt/titlegt
  ltauthorgt???lt/authorgt   ltpricegt120lt/pricegt  
lt/bookgt   lt/libgt
5
1.?? (3/4)
  • XML???
  • ???
  • ???
  • ????
  • Xquery
  • ?XML?????
  • 2007/1/23 XQuery???W3C????
  • ??????

6
1.?? (4/4)
  • XML????
  • ?????????
  • ????
  • ????
  • ???????

7
2.???? (1/4)
  • (1)????
  • DTD
  • Schema
  • (2)????
  • ??(Element)
  • ??(Attribute)
  • ????(Entity Reference)
  • CDATA??? PCDATA
  • PI(Processing Instructions)

8
2.???? (2/4)
  • XML???
  • XML-Enabled ???(XED)
  • ??XML??????
  • ?????RD?????
  • ???????XML??
  • Native XML???(NXD)
  • ????????XML
  • ??????????
  • ?????????

9
2.???? (3/4)
  • ??XML???????

10
2.???? (4/4)
  • XML????(Xquery )
  • ???XML?????
  • W3C ?1999 ???????XML
  • 2007/1??????Xquery 2.0
  • ???20?????????,??MS SQL????
  • Xquery???
  • ?XML ??????XML ?????????
  • ????????
  • ???????????
  • ??XLink?XPointer
  • ??????(Namespace Alias)??????
  • ?????????????
  • ??????????XML ???????

11
3.???SQL?? (1/10)
  • Xquery?????
  • Xpath??????
  • FLWR??
  • ????????
  • Xpath??????
  • Xpath?Xquery???
  • Xpath????????????XQuery

12
3.???SQL?? (2/10)
  • Xpath????
  • ??????????
  • //Author
  • --------------------------------------------------
  • ??store????Author
  • Document("store.xml")//Author

13
3.???SQL?? (3/10)
  • FLWR??
  • Xquery????????
  • FlwrExprFOR?LET?????????WHERE??
  • WhereClauseWHERE????????????XQuery
    ??,?????FLWR??
  • ReturnClause??????

14
3.???SQL?? (4/10)
  • FLWR????(1)

?????? LET Author//Author RETURN
Author
?????? FOR Author IN // Author
RETURN Author
15
3.???SQL?? (5/10)
  • FLWR????(2)

????????? FOR book in //book FOR author
IN book/author RETURN
author ?? ????FOR??,book???K?(??book???),???
?????FOR?????ltbookgt???ltauthorgt????????????author?
?(?????????????),???????????
16
3.???SQL?? (6/10)
  • FLWR????(3)????

??????????100????? FOR p IN
distinct(document("booklist.xml")//publisher)
LET b document(booklist.xml)/bookpublishe
r p WHERE count(b) gt 100
RETURN p
????????????????? LET a
avg(//book/price) FOR b IN /book WHERE
b/price gt a RETURN b/title
17
3.???SQL?? (7/10)
  • XQuery ????????
  • ?????????????

18
3.???SQL?? (8/10)
  • Joint??(1)
  • ????????????????????????

SQL Select c.c_Name From Customer as c, Order as
o, Product as p Where p.p_Name'???????????' and
o.pIdp.pId and c.mIdo.Mid
XML FOR p IN document("product.xml")//o_record
p_Name '???????????' o IN document("order.xml
")//o_recordpId p/pId c IN
document("customer.xml")//c_record mIdo/mId,
RETURN c/c_Name
19
3.???SQL?? (9/10)
  • Joint??(2)
  • ???????????????,???????????

SQL Select c.c_Name, p.p_Name From Customer as
c, Order as o, Product as p Where o.pIdp.pId and
c.mIdo.Mid
XML FOR c IN document(customer1.xml)//c_recor
d RETURN ltcustomer1gt c/c_Name
FOR o IN document(order.xml)// order_record
mId o/mId p IN
document(product.xml)//product_record pId
o/pId RETURN p/p_Name
lt/customer1 gt
20
3.???SQL?? (10/10)
  • Group??? (1)
  • ????????????????????

SQL SELECT avg(p_Price) AS avgprice FROM order
GROUP BY pId HAVING count() gt 5
XML FOR op IN distinct(document("order.xml")/
/pId) LET o document("customer1")//order_rec
ordpId op WHERE count(o) gt5 RETURN
ltcustomer1gt op, ltavgpricegt
avg(o/price) lt/avgpricegt lt/ customer1gt
21
4. XML??????????? (1/3)
  • Tamino??
  • ?????XML???(NXD)
  • ??Software AG??
  • ????
  • 1.X-Engine
  • 2.Data Map
  • 3.Tamino Manager
  • ??????
  • 1.Tamino Schema Editor
  • 2. Tamino X-Plorer
  • 3. Tamino X-Application

22
4. XML??????????? (2/3)
  • Xquery??????(1)
  • ??????(Tamino-1??,MS SQL??)

23
4. XML??????????? (3/3)
  • Xquery??????(2)
  • ?????????(Tamino-1??,MS SQL??)

24
5.??
  • 1. XML??????????????,?XQuery ??XML?????,??XQuery
    ??????????
  • 2. XQuery ?????????????,??????????Update????
  • 3. XQuery ???????SQL??????,????????????????
  • 4. XML?SQL????10??????,???????????

25
Q A
Write a Comment
User Comments (0)
About PowerShow.com