Content-type: text/html; charset=UTF-8 Man page of qddb_view

qddb_view

Section: Herrin Software Development, Inc. (1)
Updated: 21 Oct 2000
Index Return to Main Contents
 

NAME

qddb_view - Create/manipulate Qddb views.  

SYNOPSIS

qddb_view define <tuple desc>|<row desc> <attribute name/TCL var pairs>
qddb_view set <view desc> <row desc>
qddb_view get <view desc>
qddb_view refresh <view desc>|all
qddb_view delete <view desc>|all

 

DESCRIPTION

A view is a set of attributes within a single row of a Qddb tuple. A row is defined as any combination of attributes where any two attributes in the row are within the same instance of their nearest common ancestor in the schema. For example, the schema:
        Client (
                Name ( First Middle Last )*
                Address ( Street City State Zip )*
        )*
may have a complete row consisting of:
        Client.Name.First
        Client.Name.Middle
        Client.Name.Last
        Client.Address.Street
        Client.Address.City
        Client.Address.State
        Client.Address.Zip
Any two of these attributes in one row must be in the same instance of Client and the attributes Client.Address.City and Client.Address.State must both be in the same instance of Client.Address if they are both in the same row. So, for the following tuple in readable format conforming to the schema presented above:
        Client (
                Name (
                        First = "Eric"
                        Middle = "H."
                        Last = "Herrin"
                )
                Name (
                        First = "Sharon"
                        Last = "Rosh"
                )
                Address (
                        Street = "123 Howard Drive"
                        City = "Lexington"
                        State = "Kentucky"
                        Zip = "40506"
                )
                Address (
                        Street = "321 Jimbob Lane"
                        City = "Rallies"
                        State = "Virginia"
                        Zip = "12345"
                )
        )
the possible rows are:
Eric:H.:Herrin:123 Howard Drive:Lexington:Kentucky:40506
Eric:H.:Herrin:321 Jimbob Lane:Rallies:Virginia:12345
Sharon::Rosh:123 Howard Drive:Lexington:Kentucky:40506
Sharon::Rosh:321 Jimbob Lane:Rallies:Virginia:12345

qddb_view define
defines a view on the Qddb tuple described by <tuple_desc>. The <attribute,var> list is in the format:
        { {Client.Name.First array(Client.Name.First)}
          {Client.Name.Last  array(Client.Name.Last)}
          {Client.Address.Street street_var}
        }
and will associate the TCL variable array(Client.Name.First) with the attribute Client.Name.First in the row described by the view. When a view is defined, the first instance of each attribute is used in the row. The view may be changed by using qddb_view set or qddb_instance switch. Multiple views on a single tuple may be defined. The specified variables are global.

qddb_view set
switches the row used in <view_desc> to the row described by <row_desc>.

qddb_view get
returns a new <row_desc> for the current row used in <view_desc>.

qddb_view refresh
refreshes all view variables described by the <view_desc>. The special <view_desc> all instructs Qddb to refresh all currently defined views. This is usually only necessary to update Tk widgets.

qddb_view delete
deletes the view described by the <view_desc>. The special <view_desc> all instructs Qddb to remove all views from memory.

 

SEE ALSO

qddb_instance(n), qddb_keylist(n), qddb_rows(n), qddb_schema(n), qddb_search(n), qddb_tuple(n)  

REFERENCES

A Guide to QDDB
Eric H. Herrin II and Raphael A. Finkel

Qddb User's Guide

An ASCII Database for Fast Queries of Relatively Stable Data
Eric H. Herrin II and Raphael A. Finkel
Computing Systems, Volume 4 Number 2
University of California Press, Berkeley CA

Schema and Tuple Trees: An Intuitive Structure for 
Representing Relational Data
Eric H. Herrin, II and Raphael A. Finkel
Computing Systems, Volume 9, Number 2
MIT Press, Cambridge MA

TCL and the TK Toolkit 
John K. Ousterhout
Addison-Wesley, 1994
ISBN 0-201-63337-X
 

DIAGNOSTICS

 

BUGS

None known.


 

Index

NAME
SYNOPSIS
DESCRIPTION
SEE ALSO
REFERENCES
DIAGNOSTICS
BUGS

This document was created by man2html, using the manual pages.
Time: 18:55:30 GMT, October 31, 2018