9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
* [9fans] Plan9 Relational Databases
@ 2001-02-08 18:57 Mark Otto
  2001-02-08 19:31 ` [9fans] " Vincent D Murphy
  0 siblings, 1 reply; 8+ messages in thread
From: Mark Otto @ 2001-02-08 18:57 UTC (permalink / raw)
  To: 9fans

Geoff touches on some interesting points.

Why use relational databases (RDBs)?
I think RDBs are useful.  If you set up your data as relational
tables(one table describing a one-to-one relationship, two tables
describing a one-to-many relationship, and three tables describing a
many-to-many relationship), you can be assured that your data is
consistent and can be manipulated with a few simple operations.  Why
make a new format and tools for each data set.  Also, and improvement
in any of the RDB tools would improve the performance of all the
databases.  Someone know RDB basics could make their way through
/lib/vgadb or /lib/ndb/local with basic RDB tools without knowing
their special formats.  They could be manipulated without specific
tools too.  The down side is that what is concisely in one table would
be spread over many tables (still in ASCII or unicode) and in some
description of the relation between the tables.

Why use SQL?
On one hand, I agree, why have another proprietary format to convert
in and out of and interactive language to learn and to get into and
out of?  I used a version of /rdb ([www.rdb.com]) you have to look
past the fact that they are rabid UNIX fans), a RDB Management System
(RDBMS) that extended unix commands do the SQL selects, where,
expressions, joins, order bys, and group bys.  Col selected and
rearraigned columns, row selected rows, compute provided a front-end
to awk to allow the straight forward use of column names, join merged
files, sort, etc.  Each of the commands input and output ascii files.
There was only ve, a vi type editor to input and check tables as an
RDBMS might.  (Acme could provide a much better interface for this.)
The file permissions provided the security.  One could mimic SQL with
unix commands piped together.  Their argument was that computer and
versions of unix where getting so fast that the basic OS could do most
of the work.  Then you use already familiar other UNIX commands to
handle any other tasks (say tbl and troff to present tables).  There
was getting in and out of the system or data in and out.  (But, maybe
this is what Steve Kilbane, 2000-July.txt, was warning against.)

I use the Bell Labs S, (actually the freeware R, a derivative of
Splus), which is a nice language to do statistical analysis and
graphing.  It still has the hassles of getting data in and out of it
and getting in and out of the interpreter.  A /rdb system or `little
language' might be a better approach.

On the other hand, in SQL you can specify all the manipulations
(selects, joins, sorts, ...)  in one command without having to
consider the step by step way that they should be carried out.  The
system should figure the most efficient way to execute the steps and
store the data.  Once the tables and the relations (keys) among them
are defined, the manipulations are straight forward (E.  F. Codd's
relational calculus that describes RDBs is elegant).

A couple of months ago, Bill Staniewicz asked about what RDBMSs are
used in plan9 if any.  I didn't see anyone respond to this, but all I
have seen is the following:

1997-September.txt: G. David Butler discussed adding transaction
semantics to plan9 and 9p to help develop distributed databases.  (He
seems to have dropped off the face of the earth after version 3 came
out.  He sounded like he wanted to market plan9 version 3 with these
extensions.  I don't know whatever happened with this.)

2000-August.txt: Stephan Harris and Nick Gorham talked about making
Postgress a stand alone database.

2000-October.txt: Kenji Okamoto
([http://basalt.cias.osakafu-u.ac.jp/plan9]) made a Postgres (version
4) client monitor.

2001-January.txt: Matt Heath pointed out a linux project to make MySQL
into a file server ([http://no.spam.ee/~tonu/mysqlfs.html]).  They
make the each data item a file with the rows, columns, and tables as
directories.  To me, this is taking the fileserver idea too far.  With
tables, each row has the same columns, hierarchical filesystems do not
have to maintain that consistency.  I think an FS where the database
is directory and the schema, tables, and queries are files would
better.

Do others have an idea of what a plan9 RDB FS should look like?

Mark






^ permalink raw reply	[flat|nested] 8+ messages in thread

* [9fans] Re: Plan9 Relational Databases
  2001-02-08 18:57 [9fans] Plan9 Relational Databases Mark Otto
@ 2001-02-08 19:31 ` Vincent D Murphy
  0 siblings, 0 replies; 8+ messages in thread
From: Vincent D Murphy @ 2001-02-08 19:31 UTC (permalink / raw)
  To: 9fans

= Mark Otto <Mark_Otto@FWS.Gov> [20010208 1859]:
> Do others have an idea of what a plan9 RDB FS should look like?

i think the real challenge is in providing ACID while keeping 9p simple,
clear, and general; the interface would follow.

i don't think defining the interface is the real challenge.  surely,
the structure and semantics of the fs could be devised the same way they
are for any 9p fileserver, (e.g. /net).  essentially the only argument
left to be resolved is how granular the fs should be; should files be
rows or entire tables (shooting from the hip, i would say the latter,
though taking efficient query evalutation into account may shift the
goalposts somewhat).

i wonder could joins be done with bind(2) though; that would be just
too cool.  :)

perhaps it's worth mentioning that the tux2 filesystem for linux promised
atomic writes using a method similar to that in netapp's woffle fs.
maybe that's somewhere to start.  http://innominate.org/~phillips/tux2


^ permalink raw reply	[flat|nested] 8+ messages in thread

* [9fans] Plan9 Relational Databases
@ 2001-02-09 16:40 William Staniewicz
  0 siblings, 0 replies; 8+ messages in thread
From: William Staniewicz @ 2001-02-09 16:40 UTC (permalink / raw)
  To: 9fans, vecera; +Cc: vecera

I have been using SAM to manually enter records
into the Data file of PQ. I think it might be more
"user friendly" to set up a template; run the
template through sed or awk; then append that
to the Data file.

		-Bill




^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [9fans] Plan9 Relational Databases
@ 2001-02-09 14:40 William Staniewicz
  0 siblings, 0 replies; 8+ messages in thread
From: William Staniewicz @ 2001-02-09 14:40 UTC (permalink / raw)
  To: 9fans; +Cc: ishwar

It is at the bottom of the "Updates" page the last time
I looked.

		-Bill

> >> A couple of months ago, Bill Staniewicz asked about what RDBMSs are
> >> used in plan9 if any.  I didn't see anyone respond to this, but all I
> >> have seen is the following:
>
> > I responded to Bill directly and should have sent this out to the list.
>
> > At the bottom of the distribution page is a tar file for 'pq'.
>
>                        ^^^^^^^^^^^^
> What is the URL for this page?
>
> - ishwar



^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [9fans] Plan9 Relational Databases
  2001-02-08 20:15 [9fans] " diaz
  2001-02-09  2:01 ` Ish Rattan
@ 2001-02-09  9:41 ` vecera
  1 sibling, 0 replies; 8+ messages in thread
From: vecera @ 2001-02-09  9:41 UTC (permalink / raw)
  To: 9fans

How could I insert a record into database?

vecera

> The distribution includes a sample set of relations you can
> experiment with, man pages, etc.
>
> Finally, I have to say that despite the attribution on the web page,
> pq is the work of Michael Baldwin (who is now at Vita Nuova -
> baldwin@vitanuova.com).  I merely packaged it up.
> Given that, I'd be happy to answer any questions you may
> have.
>
> Hope you find it useful.
>
>


Sent via Deja.com
http://www.deja.com/


^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [9fans] Plan9 Relational Databases
  2001-02-09  2:01 ` Ish Rattan
@ 2001-02-09  9:40   ` nw
  0 siblings, 0 replies; 8+ messages in thread
From: nw @ 2001-02-09  9:40 UTC (permalink / raw)
  To: 9fans

On Fri, 9 Feb 2001 02:17:56 GMT, ishwar@pali.cps.cmich.edu (Ish
Rattan) wrote:

>In article <20010208201814.5990119AD4@mail.cse.psu.edu> you wrote:
>> At the bottom of the distribution page is a tar file for 'pq'.
>                       ^^^^^^^^^^^^
>What is the URL for this page?

start here:

	http://plan9.bell-labs.com/plan9dist/ureg.html

bottom of next page.


^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [9fans] Plan9 Relational Databases
  2001-02-08 20:15 [9fans] " diaz
@ 2001-02-09  2:01 ` Ish Rattan
  2001-02-09  9:40   ` nw
  2001-02-09  9:41 ` vecera
  1 sibling, 1 reply; 8+ messages in thread
From: Ish Rattan @ 2001-02-09  2:01 UTC (permalink / raw)
  To: 9fans

In article <20010208201814.5990119AD4@mail.cse.psu.edu> you wrote:

>> A couple of months ago, Bill Staniewicz asked about what RDBMSs are
>> used in plan9 if any.  I didn't see anyone respond to this, but all I
>> have seen is the following:

> I responded to Bill directly and should have sent this out to the list.

> At the bottom of the distribution page is a tar file for 'pq'.

                       ^^^^^^^^^^^^
What is the URL for this page?

- ishwar


^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: [9fans] Plan9 Relational Databases
@ 2001-02-08 20:15 diaz
  2001-02-09  2:01 ` Ish Rattan
  2001-02-09  9:41 ` vecera
  0 siblings, 2 replies; 8+ messages in thread
From: diaz @ 2001-02-08 20:15 UTC (permalink / raw)
  To: 9fans

> A couple of months ago, Bill Staniewicz asked about what RDBMSs are
> used in plan9 if any.  I didn't see anyone respond to this, but all I
> have seen is the following:

I responded to Bill directly and should have sent this out to the list.

At the bottom of the distribution page is a tar file for 'pq'.

It is an "implicit" rdb in that joins are done across the relations
dynamically.  You create your relations and  describe the schemata
in a dispatch file.  When queries are made the join code figures
out the best way to link the relations to resolve the query.
It also (cleanly) supports distributed relations.

It has a lot of flexibility and power, and more functionality
than my hastily put together documentation describes.
It has seen a lot of heavy, production use over the years
in a variety of applications.  As an example, one directory
application currently supports 20 million lookups per month.

The distribution includes a sample set of relations you can
experiment with, man pages, etc.

Finally, I have to say that despite the attribution on the web page,
pq is the work of Michael Baldwin (who is now at Vita Nuova -
baldwin@vitanuova.com).  I merely packaged it up.
Given that, I'd be happy to answer any questions you may
have.

Hope you find it useful.



^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2001-02-09 16:40 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2001-02-08 18:57 [9fans] Plan9 Relational Databases Mark Otto
2001-02-08 19:31 ` [9fans] " Vincent D Murphy
2001-02-08 20:15 [9fans] " diaz
2001-02-09  2:01 ` Ish Rattan
2001-02-09  9:40   ` nw
2001-02-09  9:41 ` vecera
2001-02-09 14:40 William Staniewicz
2001-02-09 16:40 William Staniewicz

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).