25
VIQING Visual Interactive QueryING Chris Olston UC Berkeley 14th IEEE Symposium on Visual Languages Halifax, Nova Scotia, Canada September 1st - 4th, 1998 uthors ris Olston, Michael Stonebraker, exander Aiken, Joseph M. Hellerstein

VI Q ING V isual I nteractive Q ueryING Chris Olston UC Berkeley 14th IEEE Symposium on Visual Languages Halifax, Nova Scotia, Canada September 1st - 4th,

  • View
    213

  • Download
    0

Embed Size (px)

Citation preview

Page 1: VI Q ING V isual I nteractive Q ueryING Chris Olston UC Berkeley 14th IEEE Symposium on Visual Languages Halifax, Nova Scotia, Canada September 1st - 4th,

VIQING

Visual Interactive QueryING

Chris Olston

UC Berkeley

14th IEEE Symposium on Visual Languages Halifax, Nova Scotia, Canada September 1st - 4th, 1998

AuthorsChris Olston, Michael Stonebraker, Alexander Aiken, Joseph M. Hellerstein

Page 2: VI Q ING V isual I nteractive Q ueryING Chris Olston UC Berkeley 14th IEEE Symposium on Visual Languages Halifax, Nova Scotia, Canada September 1st - 4th,

VIQING Chris Olston, UC Berkeley

Outline

• Introduction– Related Work– Background

• Visual query results

• Specifying visual queries

• How VIQING generalizes other work

• Status and future work

Page 3: VI Q ING V isual I nteractive Q ueryING Chris Olston UC Berkeley 14th IEEE Symposium on Visual Languages Halifax, Nova Scotia, Canada September 1st - 4th,

VIQING Chris Olston, UC Berkeley

Introduction

• Databases are hard to use– Difficult to understand data in textual form– SQL query language hard to learn

• Visual Programming Can Help!– Database visualization systems (like

DataSplash) display data in graphical form

– VIQING provides a simple interface for expressing queries over visualizations ?

Page 4: VI Q ING V isual I nteractive Q ueryING Chris Olston UC Berkeley 14th IEEE Symposium on Visual Languages Halifax, Nova Scotia, Canada September 1st - 4th,

VIQING Chris Olston, UC Berkeley

• Other interfaces offer visual programming– Visualization

• QBE, Cupid, Tioga-1, AVS, Khoros, MS-Access, DEVise

– Querying• 4GLs, Tioga-1, AVS, Khoros, Access, DEVise, Magic Lenses

• But only VIQING/DataSplash offers a unified visual programming model for visualization and visual querying

?

Related Work

?

Page 5: VI Q ING V isual I nteractive Q ueryING Chris Olston UC Berkeley 14th IEEE Symposium on Visual Languages Halifax, Nova Scotia, Canada September 1st - 4th,

VIQING Chris Olston, UC Berkeley

Background

• DataSplash is a data visualization tool that displays database data in graphical form– Each row in a database table gets translated

into one graphical object on a canvas

1.52322.82383.9221

Database

One rowTable Canvas

DataSplash

Page 6: VI Q ING V isual I nteractive Q ueryING Chris Olston UC Berkeley 14th IEEE Symposium on Visual Languages Halifax, Nova Scotia, Canada September 1st - 4th,

VIQING Chris Olston, UC Berkeley

Example DataSplash Visualization

• This visualization shows which political party each state has favored since 1952

• A DataSplash canvas can be infinitely panned and zoomed

Red: DemocratBlue: Republican

Each state is one database row

Page 7: VI Q ING V isual I nteractive Q ueryING Chris Olston UC Berkeley 14th IEEE Symposium on Visual Languages Halifax, Nova Scotia, Canada September 1st - 4th,

VIQING Chris Olston, UC Berkeley

Portals: Nested Visualizations

• Portals are sub-windows in one canvas that show another canvas

• Portals can be independently panned and zoomed

Bush ‘88 Clinton ‘92

Bush ‘92Dukakis ‘88A Portal

This portal contains a canvas of presidential candidates ordered by year (X axis), with the winner on top (Y axis)

Page 8: VI Q ING V isual I nteractive Q ueryING Chris Olston UC Berkeley 14th IEEE Symposium on Visual Languages Halifax, Nova Scotia, Canada September 1st - 4th,

VIQING Chris Olston, UC Berkeley

Outline

• Introduction– Related Work– Background

• Visual query results

• Specifying visual queries

• How VIQING generalizes other work

• Status and future work

Page 9: VI Q ING V isual I nteractive Q ueryING Chris Olston UC Berkeley 14th IEEE Symposium on Visual Languages Halifax, Nova Scotia, Canada September 1st - 4th,

VIQING Chris Olston, UC Berkeley

Visual Selection

• A visual selection displays only rows that pass a selection filter– Which states voted Democratic in 1992?

Note that all red (traditionally Democratic) states voted Democratic in 1992

?

Page 10: VI Q ING V isual I nteractive Q ueryING Chris Olston UC Berkeley 14th IEEE Symposium on Visual Languages Halifax, Nova Scotia, Canada September 1st - 4th,

VIQING Chris Olston, UC Berkeley

Visual Join

• A visual join ( ) combines information from two or more database tables via portals

Presidential Candidates States

Each presidential candidate has a portal containing the states that voted for him

One join portal for every row in the candidates table

?

Page 11: VI Q ING V isual I nteractive Q ueryING Chris Olston UC Berkeley 14th IEEE Symposium on Visual Languages Halifax, Nova Scotia, Canada September 1st - 4th,

VIQING Chris Olston, UC Berkeley

Outline

• Introduction– Related Work– Background

• Visual query results

• Specifying visual queries

• How VIQING generalizes other work

• Status and future work

Page 12: VI Q ING V isual I nteractive Q ueryING Chris Olston UC Berkeley 14th IEEE Symposium on Visual Languages Halifax, Nova Scotia, Canada September 1st - 4th,

VIQING Chris Olston, UC Berkeley

User Interface: Performing a Visual Selection

• Select graphical rows by rubber-banding

• The result:

– The canvas inside the portal has only 6 rows– Selection portals can be used for visual joins ...

?

A portal that contains only the selected rows

Page 13: VI Q ING V isual I nteractive Q ueryING Chris Olston UC Berkeley 14th IEEE Symposium on Visual Languages Halifax, Nova Scotia, Canada September 1st - 4th,

VIQING Chris Olston, UC Berkeley

Performing a Visual Join?• Drag . . . . . . . . and Drop

VIQING Chris Olston, UC Berkeley

Join 1960’s presidential candidates with political parties

Page 14: VI Q ING V isual I nteractive Q ueryING Chris Olston UC Berkeley 14th IEEE Symposium on Visual Languages Halifax, Nova Scotia, Canada September 1st - 4th,

VIQING Chris Olston, UC Berkeley

The Result: A Three-Level Visual Join

• Now candidates are joined with political parties– We know which

candidates belong to which parties

– Can see trends for each party over time

?

Parties Candidates States

Page 15: VI Q ING V isual I nteractive Q ueryING Chris Olston UC Berkeley 14th IEEE Symposium on Visual Languages Halifax, Nova Scotia, Canada September 1st - 4th,

VIQING Chris Olston, UC Berkeley

Visual Reordering

• Visual queries have an ordering

• Visual reordering can be performed after the join– To reorder: drop a

portal onto a row of its child canvas

?

Parties Candidates States

Page 16: VI Q ING V isual I nteractive Q ueryING Chris Olston UC Berkeley 14th IEEE Symposium on Visual Languages Halifax, Nova Scotia, Canada September 1st - 4th,

VIQING Chris Olston, UC Berkeley

Result of Visual Reordering

• Now, parties join with states, which join with candidates– We can see the

voting history of each state, by traditional party

?

Parties States Candidates

Georgia voted with the other Democrat states in ‘60, but against them in ‘64

Page 17: VI Q ING V isual I nteractive Q ueryING Chris Olston UC Berkeley 14th IEEE Symposium on Visual Languages Halifax, Nova Scotia, Canada September 1st - 4th,

VIQING Chris Olston, UC Berkeley

Benefits of VIQING Queries

• Easier to use than SQL– Can incrementally build and refine queries– Query manipulations on custom graphical

representation of data, which is easier to understand than text

– Don’t need to know SQL syntax -- just drag and drop (direct-manipulation)

Page 18: VI Q ING V isual I nteractive Q ueryING Chris Olston UC Berkeley 14th IEEE Symposium on Visual Languages Halifax, Nova Scotia, Canada September 1st - 4th,

VIQING Chris Olston, UC Berkeley

Join Predicates

• We have not discussed how VIQING knows what join predicates to use

• In most cases, join predicates are equality– eg, candidate.party_name = party.party_name– These can be inferred from foreign key

relationships defined at schema creation time

• Alternatively, could specify more general join predicates with a tool like MS Access

Page 19: VI Q ING V isual I nteractive Q ueryING Chris Olston UC Berkeley 14th IEEE Symposium on Visual Languages Halifax, Nova Scotia, Canada September 1st - 4th,

VIQING Chris Olston, UC Berkeley

Removing Intermediate Tables

• Often, 2 tables join via an intermediate table– eg, Candidates Vote records States

• However, we don’t want to see the intermediate table– we want Candidates States

• To do this, visually remove intermediate– Drag intermediate portal away from the canvas

92-TX-R

Page 20: VI Q ING V isual I nteractive Q ueryING Chris Olston UC Berkeley 14th IEEE Symposium on Visual Languages Halifax, Nova Scotia, Canada September 1st - 4th,

VIQING Chris Olston, UC Berkeley

Outline

• Introduction– Related Work– Background

• Visual query results

• Specifying visual queries

• How VIQING generalizes other work

• Status and future work

Page 21: VI Q ING V isual I nteractive Q ueryING Chris Olston UC Berkeley 14th IEEE Symposium on Visual Languages Halifax, Nova Scotia, Canada September 1st - 4th,

VIQING Chris Olston, UC Berkeley

How VIQING Generalizes Other Work

• VIQING generalizes nested report writers– Each level of nesting is a set of join portals– Drill-down performed by entering a join portal

• VIQING generalizes master/detail forms– Master-detail relationship is a join– Data entry support could be added to

DataSplash

Page 22: VI Q ING V isual I nteractive Q ueryING Chris Olston UC Berkeley 14th IEEE Symposium on Visual Languages Halifax, Nova Scotia, Canada September 1st - 4th,

VIQING Chris Olston, UC Berkeley

Generalizing “Small Multiple” Graphs

• VIQING can create “small multiple” graphs– Several views of a graph, indexed by a variable

– This is a visual join between a canvas which contains several values for the index variable and the graph canvas

Z = 5 Z = 10

Page 23: VI Q ING V isual I nteractive Q ueryING Chris Olston UC Berkeley 14th IEEE Symposium on Visual Languages Halifax, Nova Scotia, Canada September 1st - 4th,

VIQING Chris Olston, UC Berkeley

Status and Future Work

• Implemented as an extension to DataSplash

• Future work:– Support for more SQL query expressibility

• aggregates, subqueries, etc.

– An automatic way to expose meta-data• Which portals correspond to which tables?

– Improved support for large data sets • This is a DataSplash issue, orthogonal to VIQING

Page 24: VI Q ING V isual I nteractive Q ueryING Chris Olston UC Berkeley 14th IEEE Symposium on Visual Languages Halifax, Nova Scotia, Canada September 1st - 4th,

VIQING Chris Olston, UC Berkeley

Summary

• VIQING combines querying with visualization by using portals– Construct basic SQL queries by direct

manipulation of pictorial data• Visual select, join, reorder, remove intermediate

– Create nested reports, master/detail forms– Generate “small multiple” graphs

?

Page 25: VI Q ING V isual I nteractive Q ueryING Chris Olston UC Berkeley 14th IEEE Symposium on Visual Languages Halifax, Nova Scotia, Canada September 1st - 4th,

VIQING Chris Olston, UC Berkeley

For more info...

• Paper in Proc. Visual Languages 1998– Or my web page:

http://datasplash.cs.berkeley.edu/cao

• Email me: [email protected]