SlideShare uma empresa Scribd logo
1 de 29
Minimization of SuperSQL Execution Time by Query DecompositionToyama LaboratoryMidterm PresentationRia Mae Borromeo25 December 2010
Introduction (1) an extension of SQL that provides the capability of generating various kinds of application data directly as a result of a query  2
3
Introduction (2) GENERATE HTML { { imagefile(path="C:ebpage", "prc_logoback.gif"), imagefile(path="C:ebpage", "main_top02.gif") @{valign=middle, align=center} } @{bgcolor="#296793", width="600"}! ""@{border-width=0, height=20}! "August 2010 Physician Licensure Exam"@{font-size=20, align="center"}! { {"List of Exams"@{align="center", font-size=14}! [link(t.t_name@{font-size=12, width=150}, file="",  att="")@{border-width=0}]! }@{valign=top}, {"List of Passers"@{align="center", font-size=14}! [e.e_name@{font-size=10, border-width=0}]! }@{width=330, align=left, valign=top}, {"List of Schools"@{align="center", font-size=14}! [s.s_name@{font-size=10, border-width=0}]! }@{width=330, align=left, valign=top} }@{align="center"} } FROM examinee e, school s, examtype t 4 Remove decorations
Introduction (3) GENERATE HTML {  {"List of Exams"![t.t_name]!}, {"List of Passers"![e.e_name]!}, {"List of Schools"![s.s_name]!} }  FROM examtype t, examinee e,    school s 5 SQL Query SELECT DISTINCT t.t_name,   e.e_name, s.s_name,  FROMexamtype t, examinee e,    school s
Problem Illustration Expected Output SELECT DISTINCT t.t_name,   e.e_name, s.s_name,  FROMexamtype t, examinee e,    school s x x 20 + 250 + 50 = 320 tuples … Intermediate Table (250,000) 6
Proposal (1) GENERATE HTML {  {"List of Exams"![t.t_name]!}, {"List of Passers"![e.e_name]!}, {"List of Schools"![s.s_name]!} }  FROM examtype t, examinee e,    school s SELECT DISTINCT t.t_name,   e.e_name, s.s_name,  FROMexamtype t, examinee e,    school s SELECT  t_name FROM examtype SELECT e_name FROM examinee SELECT s_name FROM school Expected Output … … …
Proposal (2) 3 Parts Detection of divisible queries Division of Queries Creation of SQL queries Execution of SQL queries Combination of query results 8
SuperSQL query ,[object Object]
Page decoration and query attributes are separatedstart Parse Query Parse Query Make Schema Make Schema Make SQL Statement Original Process Data Construction Execute SQL Statement Make Tree Structure Generate Code Application Data end 9
Schema A tree-structured representation of the layout of the attributes 10 [ [t.t_name], [e.e_name], [s.s_name] ]
SuperSQL query ,[object Object]
Page decoration and query attributes are separated
Make Tree Structure
The schema and the tuples from the database are combined into a tree-structure
Generate Code
Using the tree structure, code for application data is generatedstart Parse Query Parse Query Make Schema Make Schema Make SQL Statement Make SQL Statement Original Process Data Construction Execute SQL Statement Execute SQL Statement Make Tree Structure Make Tree Structure Generate Code Generate Code Application Data end 11
start SuperSQL query Parse Query Make Schema Proposed Process Check Divisibility Make SQL Statements Check Divisibility Make SQL Statement Y N Execute SQL Statement Execute SQL Statements Generate Code Make Tree Structure Combine  results into a tree structure Application Data end 12
Check Divisibility Algorithm 13 1. Get the attributes from the schema GENERATE HTML {  {"List of Exams"![t.t_name]!}, {"List of Passers"![e.e_name]!}, {"List of Schools"![s.s_name]!} }  FROM examtype t, examinee e,    school s Schema [ [t.t_name], [e.e_name], [s.s_name] ]
Check Divisibility Algorithm 14 2. Make a graph to identify relationships t.t_name s.s_name e.e_name Vertices : attributes Edges: If two attributes are from the same table If two attributes are equated in a where condition If two attributes are grouped in the schema
Check Divisibility Algorithm 15 3. Find connected components using Depth-First Search t.t_name s.s_name e.e_name Connected Component - a subgraph that contains a path between all pairs of vertices in the subgraph Depth-First Search - A search algorithm that extends the current path as far as possible before backtracking to the last choice point and trying the next alternative path. 
Example 2 16 1. Get the attributes from the schema GENERATE HTML [  f.title! {{ { "Director" ! f.dir } ! { "Running" ! f.length } }, { "Starring" ,  [ r.name %  {r.name ,  { "Birthday" , r.bday }! "Biography" ! r.bio } } ]! } }! f.story]! FROM    film f, actor r, act a WHERE   a.film = f.id AND a.act = r.id [[f.title, f.dir, f.length, [actor.name, actor.name, actor.birthday, actor.biography], f.story]]
Example 2 17 2. Make a graph to identify relationships f.story f.title f.len r.bday r.name f.dir a.act r.bio f.id r.id a.film
Example 2 18 3. Find connected components by Depth-First Search f.story f.title f.len f.len f.title r.bday r.bday r.name r.name f.dir f.dir a.act a.act r.bio r.bio f.id f.id r.id r.id a.film a.film
start SuperSQL query Parse Query Make Schema Proposed Process Check Divisibility Make SQL Statements Check Divisibility Make SQL Statements Make SQL Statement Y N Execute SQL Statement Execute SQL Statements Execute SQL Statements Generate Code Make Tree Structure Combine  results into a tree structure Combine  results into a tree structure Application Data end 19
Current Status 3 Parts Detection of divisible queries Division of Queries Creation of SQL queries Execution of SQL queries Combination of query results Trivial case: columns are independent of each other Others 20
Experiments (1) Intel (R) Core (TM)2 Duo CPU 2.09 GHz 1.97 GB RAM Microsoft Windows XP Professional  2002 SP3 Java 6 Update 22 Standard Edition 21
Experiments (2) 22 ,[object Object],[object Object]
Experiments (4) 24 No. of Attributes

Mais conteúdo relacionado

Semelhante a 20101217 mtg

닷넷 개발자를 위한 패턴이야기
닷넷 개발자를 위한 패턴이야기닷넷 개발자를 위한 패턴이야기
닷넷 개발자를 위한 패턴이야기YoungSu Son
 
SQL Training in Ambala ! Batra Computer Centre
SQL Training in Ambala ! Batra Computer CentreSQL Training in Ambala ! Batra Computer Centre
SQL Training in Ambala ! Batra Computer Centrejatin batra
 
SQLite in Adobe AIR
SQLite in Adobe AIRSQLite in Adobe AIR
SQLite in Adobe AIRPeter Elst
 
Final Project Presentation
Final Project PresentationFinal Project Presentation
Final Project Presentationzroserie
 
SQL Server - Introduction to TSQL
SQL Server - Introduction to TSQLSQL Server - Introduction to TSQL
SQL Server - Introduction to TSQLPeter Gfader
 
ADO.NET Entity Framework by Jose A. Blakeley and Michael Pizzo
ADO.NET Entity Framework by Jose A. Blakeley and Michael PizzoADO.NET Entity Framework by Jose A. Blakeley and Michael Pizzo
ADO.NET Entity Framework by Jose A. Blakeley and Michael PizzoHasnain Iqbal
 
The Django Web Application Framework 2
The Django Web Application Framework 2The Django Web Application Framework 2
The Django Web Application Framework 2fishwarter
 
The Django Web Application Framework 2
The Django Web Application Framework 2The Django Web Application Framework 2
The Django Web Application Framework 2fishwarter
 
The Django Web Application Framework 2
The Django Web Application Framework 2The Django Web Application Framework 2
The Django Web Application Framework 2fishwarter
 
The Django Web Application Framework 2
The Django Web Application Framework 2The Django Web Application Framework 2
The Django Web Application Framework 2fishwarter
 
[DSBW Spring 2009] Unit 07: WebApp Design Patterns & Frameworks (3/3)
[DSBW Spring 2009] Unit 07: WebApp Design Patterns & Frameworks (3/3)[DSBW Spring 2009] Unit 07: WebApp Design Patterns & Frameworks (3/3)
[DSBW Spring 2009] Unit 07: WebApp Design Patterns & Frameworks (3/3)Carles Farré
 
Playing with d3.js
Playing with d3.jsPlaying with d3.js
Playing with d3.jsmangoice
 
Boston Computing Review - Java Server Pages
Boston Computing Review - Java Server PagesBoston Computing Review - Java Server Pages
Boston Computing Review - Java Server PagesJohn Brunswick
 
XML-Free Programming
XML-Free ProgrammingXML-Free Programming
XML-Free ProgrammingStephen Chin
 
The vJUG talk about jOOQ: Get Back in Control of Your SQL
The vJUG talk about jOOQ: Get Back in Control of Your SQLThe vJUG talk about jOOQ: Get Back in Control of Your SQL
The vJUG talk about jOOQ: Get Back in Control of Your SQLLukas Eder
 
Extending MySQL Enterprise Monitor
Extending MySQL Enterprise MonitorExtending MySQL Enterprise Monitor
Extending MySQL Enterprise MonitorMark Leith
 
Micro-ORM Introduction - Don't overcomplicate
Micro-ORM Introduction - Don't overcomplicateMicro-ORM Introduction - Don't overcomplicate
Micro-ORM Introduction - Don't overcomplicateKiev ALT.NET
 

Semelhante a 20101217 mtg (20)

닷넷 개발자를 위한 패턴이야기
닷넷 개발자를 위한 패턴이야기닷넷 개발자를 위한 패턴이야기
닷넷 개발자를 위한 패턴이야기
 
SQL Training in Ambala ! Batra Computer Centre
SQL Training in Ambala ! Batra Computer CentreSQL Training in Ambala ! Batra Computer Centre
SQL Training in Ambala ! Batra Computer Centre
 
Jdbc
JdbcJdbc
Jdbc
 
SQLite in Adobe AIR
SQLite in Adobe AIRSQLite in Adobe AIR
SQLite in Adobe AIR
 
Final Project Presentation
Final Project PresentationFinal Project Presentation
Final Project Presentation
 
SQL Server - Introduction to TSQL
SQL Server - Introduction to TSQLSQL Server - Introduction to TSQL
SQL Server - Introduction to TSQL
 
ADO.NET Entity Framework by Jose A. Blakeley and Michael Pizzo
ADO.NET Entity Framework by Jose A. Blakeley and Michael PizzoADO.NET Entity Framework by Jose A. Blakeley and Michael Pizzo
ADO.NET Entity Framework by Jose A. Blakeley and Michael Pizzo
 
The Django Web Application Framework 2
The Django Web Application Framework 2The Django Web Application Framework 2
The Django Web Application Framework 2
 
The Django Web Application Framework 2
The Django Web Application Framework 2The Django Web Application Framework 2
The Django Web Application Framework 2
 
The Django Web Application Framework 2
The Django Web Application Framework 2The Django Web Application Framework 2
The Django Web Application Framework 2
 
The Django Web Application Framework 2
The Django Web Application Framework 2The Django Web Application Framework 2
The Django Web Application Framework 2
 
[DSBW Spring 2009] Unit 07: WebApp Design Patterns & Frameworks (3/3)
[DSBW Spring 2009] Unit 07: WebApp Design Patterns & Frameworks (3/3)[DSBW Spring 2009] Unit 07: WebApp Design Patterns & Frameworks (3/3)
[DSBW Spring 2009] Unit 07: WebApp Design Patterns & Frameworks (3/3)
 
Playing with d3.js
Playing with d3.jsPlaying with d3.js
Playing with d3.js
 
I Feel Pretty
I Feel PrettyI Feel Pretty
I Feel Pretty
 
Boston Computing Review - Java Server Pages
Boston Computing Review - Java Server PagesBoston Computing Review - Java Server Pages
Boston Computing Review - Java Server Pages
 
XML-Free Programming
XML-Free ProgrammingXML-Free Programming
XML-Free Programming
 
The vJUG talk about jOOQ: Get Back in Control of Your SQL
The vJUG talk about jOOQ: Get Back in Control of Your SQLThe vJUG talk about jOOQ: Get Back in Control of Your SQL
The vJUG talk about jOOQ: Get Back in Control of Your SQL
 
Coding Ajax
Coding AjaxCoding Ajax
Coding Ajax
 
Extending MySQL Enterprise Monitor
Extending MySQL Enterprise MonitorExtending MySQL Enterprise Monitor
Extending MySQL Enterprise Monitor
 
Micro-ORM Introduction - Don't overcomplicate
Micro-ORM Introduction - Don't overcomplicateMicro-ORM Introduction - Don't overcomplicate
Micro-ORM Introduction - Don't overcomplicate
 

Último

Digital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptxDigital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptxLoriGlavin3
 
QCon London: Mastering long-running processes in modern architectures
QCon London: Mastering long-running processes in modern architecturesQCon London: Mastering long-running processes in modern architectures
QCon London: Mastering long-running processes in modern architecturesBernd Ruecker
 
Zeshan Sattar- Assessing the skill requirements and industry expectations for...
Zeshan Sattar- Assessing the skill requirements and industry expectations for...Zeshan Sattar- Assessing the skill requirements and industry expectations for...
Zeshan Sattar- Assessing the skill requirements and industry expectations for...itnewsafrica
 
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyes
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyesHow to Effectively Monitor SD-WAN and SASE Environments with ThousandEyes
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyesThousandEyes
 
Testing tools and AI - ideas what to try with some tool examples
Testing tools and AI - ideas what to try with some tool examplesTesting tools and AI - ideas what to try with some tool examples
Testing tools and AI - ideas what to try with some tool examplesKari Kakkonen
 
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...Alkin Tezuysal
 
A Framework for Development in the AI Age
A Framework for Development in the AI AgeA Framework for Development in the AI Age
A Framework for Development in the AI AgeCprime
 
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24Mark Goldstein
 
UiPath Community: Communication Mining from Zero to Hero
UiPath Community: Communication Mining from Zero to HeroUiPath Community: Communication Mining from Zero to Hero
UiPath Community: Communication Mining from Zero to HeroUiPathCommunity
 
TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024Lonnie McRorey
 
Time Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directionsTime Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directionsNathaniel Shimoni
 
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024BookNet Canada
 
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptxPasskey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptxLoriGlavin3
 
[Webinar] SpiraTest - Setting New Standards in Quality Assurance
[Webinar] SpiraTest - Setting New Standards in Quality Assurance[Webinar] SpiraTest - Setting New Standards in Quality Assurance
[Webinar] SpiraTest - Setting New Standards in Quality AssuranceInflectra
 
Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)Kaya Weers
 
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxUse of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxLoriGlavin3
 
Generative AI - Gitex v1Generative AI - Gitex v1.pptx
Generative AI - Gitex v1Generative AI - Gitex v1.pptxGenerative AI - Gitex v1Generative AI - Gitex v1.pptx
Generative AI - Gitex v1Generative AI - Gitex v1.pptxfnnc6jmgwh
 
React Native vs Ionic - The Best Mobile App Framework
React Native vs Ionic - The Best Mobile App FrameworkReact Native vs Ionic - The Best Mobile App Framework
React Native vs Ionic - The Best Mobile App FrameworkPixlogix Infotech
 
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...Wes McKinney
 
2024 April Patch Tuesday
2024 April Patch Tuesday2024 April Patch Tuesday
2024 April Patch TuesdayIvanti
 

Último (20)

Digital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptxDigital Identity is Under Attack: FIDO Paris Seminar.pptx
Digital Identity is Under Attack: FIDO Paris Seminar.pptx
 
QCon London: Mastering long-running processes in modern architectures
QCon London: Mastering long-running processes in modern architecturesQCon London: Mastering long-running processes in modern architectures
QCon London: Mastering long-running processes in modern architectures
 
Zeshan Sattar- Assessing the skill requirements and industry expectations for...
Zeshan Sattar- Assessing the skill requirements and industry expectations for...Zeshan Sattar- Assessing the skill requirements and industry expectations for...
Zeshan Sattar- Assessing the skill requirements and industry expectations for...
 
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyes
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyesHow to Effectively Monitor SD-WAN and SASE Environments with ThousandEyes
How to Effectively Monitor SD-WAN and SASE Environments with ThousandEyes
 
Testing tools and AI - ideas what to try with some tool examples
Testing tools and AI - ideas what to try with some tool examplesTesting tools and AI - ideas what to try with some tool examples
Testing tools and AI - ideas what to try with some tool examples
 
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...
Unleashing Real-time Insights with ClickHouse_ Navigating the Landscape in 20...
 
A Framework for Development in the AI Age
A Framework for Development in the AI AgeA Framework for Development in the AI Age
A Framework for Development in the AI Age
 
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
Arizona Broadband Policy Past, Present, and Future Presentation 3/25/24
 
UiPath Community: Communication Mining from Zero to Hero
UiPath Community: Communication Mining from Zero to HeroUiPath Community: Communication Mining from Zero to Hero
UiPath Community: Communication Mining from Zero to Hero
 
TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024
 
Time Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directionsTime Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directions
 
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
 
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptxPasskey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptx
 
[Webinar] SpiraTest - Setting New Standards in Quality Assurance
[Webinar] SpiraTest - Setting New Standards in Quality Assurance[Webinar] SpiraTest - Setting New Standards in Quality Assurance
[Webinar] SpiraTest - Setting New Standards in Quality Assurance
 
Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)
 
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptxUse of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
Use of FIDO in the Payments and Identity Landscape: FIDO Paris Seminar.pptx
 
Generative AI - Gitex v1Generative AI - Gitex v1.pptx
Generative AI - Gitex v1Generative AI - Gitex v1.pptxGenerative AI - Gitex v1Generative AI - Gitex v1.pptx
Generative AI - Gitex v1Generative AI - Gitex v1.pptx
 
React Native vs Ionic - The Best Mobile App Framework
React Native vs Ionic - The Best Mobile App FrameworkReact Native vs Ionic - The Best Mobile App Framework
React Native vs Ionic - The Best Mobile App Framework
 
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
The Future Roadmap for the Composable Data Stack - Wes McKinney - Data Counci...
 
2024 April Patch Tuesday
2024 April Patch Tuesday2024 April Patch Tuesday
2024 April Patch Tuesday
 

20101217 mtg

  • 1. Minimization of SuperSQL Execution Time by Query DecompositionToyama LaboratoryMidterm PresentationRia Mae Borromeo25 December 2010
  • 2. Introduction (1) an extension of SQL that provides the capability of generating various kinds of application data directly as a result of a query 2
  • 3. 3
  • 4. Introduction (2) GENERATE HTML { { imagefile(path="C:ebpage", "prc_logoback.gif"), imagefile(path="C:ebpage", "main_top02.gif") @{valign=middle, align=center} } @{bgcolor="#296793", width="600"}! ""@{border-width=0, height=20}! "August 2010 Physician Licensure Exam"@{font-size=20, align="center"}! { {"List of Exams"@{align="center", font-size=14}! [link(t.t_name@{font-size=12, width=150}, file="", att="")@{border-width=0}]! }@{valign=top}, {"List of Passers"@{align="center", font-size=14}! [e.e_name@{font-size=10, border-width=0}]! }@{width=330, align=left, valign=top}, {"List of Schools"@{align="center", font-size=14}! [s.s_name@{font-size=10, border-width=0}]! }@{width=330, align=left, valign=top} }@{align="center"} } FROM examinee e, school s, examtype t 4 Remove decorations
  • 5. Introduction (3) GENERATE HTML { {"List of Exams"![t.t_name]!}, {"List of Passers"![e.e_name]!}, {"List of Schools"![s.s_name]!} } FROM examtype t, examinee e, school s 5 SQL Query SELECT DISTINCT t.t_name, e.e_name, s.s_name, FROMexamtype t, examinee e, school s
  • 6. Problem Illustration Expected Output SELECT DISTINCT t.t_name, e.e_name, s.s_name, FROMexamtype t, examinee e, school s x x 20 + 250 + 50 = 320 tuples … Intermediate Table (250,000) 6
  • 7. Proposal (1) GENERATE HTML { {"List of Exams"![t.t_name]!}, {"List of Passers"![e.e_name]!}, {"List of Schools"![s.s_name]!} } FROM examtype t, examinee e, school s SELECT DISTINCT t.t_name, e.e_name, s.s_name, FROMexamtype t, examinee e, school s SELECT t_name FROM examtype SELECT e_name FROM examinee SELECT s_name FROM school Expected Output … … …
  • 8. Proposal (2) 3 Parts Detection of divisible queries Division of Queries Creation of SQL queries Execution of SQL queries Combination of query results 8
  • 9.
  • 10. Page decoration and query attributes are separatedstart Parse Query Parse Query Make Schema Make Schema Make SQL Statement Original Process Data Construction Execute SQL Statement Make Tree Structure Generate Code Application Data end 9
  • 11. Schema A tree-structured representation of the layout of the attributes 10 [ [t.t_name], [e.e_name], [s.s_name] ]
  • 12.
  • 13. Page decoration and query attributes are separated
  • 15. The schema and the tuples from the database are combined into a tree-structure
  • 17. Using the tree structure, code for application data is generatedstart Parse Query Parse Query Make Schema Make Schema Make SQL Statement Make SQL Statement Original Process Data Construction Execute SQL Statement Execute SQL Statement Make Tree Structure Make Tree Structure Generate Code Generate Code Application Data end 11
  • 18. start SuperSQL query Parse Query Make Schema Proposed Process Check Divisibility Make SQL Statements Check Divisibility Make SQL Statement Y N Execute SQL Statement Execute SQL Statements Generate Code Make Tree Structure Combine results into a tree structure Application Data end 12
  • 19. Check Divisibility Algorithm 13 1. Get the attributes from the schema GENERATE HTML { {"List of Exams"![t.t_name]!}, {"List of Passers"![e.e_name]!}, {"List of Schools"![s.s_name]!} } FROM examtype t, examinee e, school s Schema [ [t.t_name], [e.e_name], [s.s_name] ]
  • 20. Check Divisibility Algorithm 14 2. Make a graph to identify relationships t.t_name s.s_name e.e_name Vertices : attributes Edges: If two attributes are from the same table If two attributes are equated in a where condition If two attributes are grouped in the schema
  • 21. Check Divisibility Algorithm 15 3. Find connected components using Depth-First Search t.t_name s.s_name e.e_name Connected Component - a subgraph that contains a path between all pairs of vertices in the subgraph Depth-First Search - A search algorithm that extends the current path as far as possible before backtracking to the last choice point and trying the next alternative path. 
  • 22. Example 2 16 1. Get the attributes from the schema GENERATE HTML [ f.title! {{ { "Director" ! f.dir } ! { "Running" ! f.length } }, { "Starring" , [ r.name % {r.name , { "Birthday" , r.bday }! "Biography" ! r.bio } } ]! } }! f.story]! FROM film f, actor r, act a WHERE a.film = f.id AND a.act = r.id [[f.title, f.dir, f.length, [actor.name, actor.name, actor.birthday, actor.biography], f.story]]
  • 23. Example 2 17 2. Make a graph to identify relationships f.story f.title f.len r.bday r.name f.dir a.act r.bio f.id r.id a.film
  • 24. Example 2 18 3. Find connected components by Depth-First Search f.story f.title f.len f.len f.title r.bday r.bday r.name r.name f.dir f.dir a.act a.act r.bio r.bio f.id f.id r.id r.id a.film a.film
  • 25. start SuperSQL query Parse Query Make Schema Proposed Process Check Divisibility Make SQL Statements Check Divisibility Make SQL Statements Make SQL Statement Y N Execute SQL Statement Execute SQL Statements Execute SQL Statements Generate Code Make Tree Structure Combine results into a tree structure Combine results into a tree structure Application Data end 19
  • 26. Current Status 3 Parts Detection of divisible queries Division of Queries Creation of SQL queries Execution of SQL queries Combination of query results Trivial case: columns are independent of each other Others 20
  • 27. Experiments (1) Intel (R) Core (TM)2 Duo CPU 2.09 GHz 1.97 GB RAM Microsoft Windows XP Professional 2002 SP3 Java 6 Update 22 Standard Edition 21
  • 28.
  • 29. Experiments (4) 24 No. of Attributes
  • 30. Summary Implemented an algorithm for checking if SuperSQL queries can be decomposed into several SQL Queries Queries are decomposed into several SQL queries when possible Experiments show that the procedure reduces the execution time of SuperSQL in some query cases 25
  • 31. 26
  • 32. Future Work Continue implementation of the MakeTree function to address other query classes Testing More experiments Statistical Analysis of data 27
  • 33. Comments from Panel Research Suggestions: Use database information For the example, use embedded system (with limited memory) that generates webpages Presentation Suggestion: Take note of the number of decimal points in the data Question: How can you be sure that the output generated by the new one is the same as the original? It can be verified by checking the tree structure 28
  • 34. Thank you for listening. 