Re: Pick query languages compared to SQL
- From: "murthi" <c_xyz_murthi@xxxxxxxxxxxxxxxxxxxx>
- Date: Thu, 09 Mar 2006 13:57:39 GMT
I must say that whenever I read about QM, it reassures me that maybe there's
a future for MV after all!
With regard to the sturm-und-drang on dictionaries, I suggest to Martin that
maybe he should invent a new Dict type that unambiguously defines a data
element (can't have more than 1 for an attriibute, for example) and maybe
enforce/validate this with a the cd-like verb. This would go a long way
towards data clarity at least. I guess all of use creating the dreaded
"tools" have done exactly this (the "global" dictionary). If it were
enforced in the database, we'd be a step ahead.
I have recently begun looking at QM docs. Quite good. In comparing with Uv,
I note that there's much more detail instead of a
cold description. I, for example, did not know that you could dereference
subroutine arguments by parenthesis ie:
call mysub(a,b, (c), d)
so the sub can't change them (I'd use ...,c:'',... ). Notable that QM docs
even mention dereferencing, UV and others let you figure it out.
And the extensions look good, tho' I must quibble about the odd syntax of
some BASIC extensions. And in the L type, a % sign could've been > ie
OTHER.FILE>OTHER.DICT may'been clearer. But then, I like quibbling.
Sometime soon we will be taking a hard look at QM, and I hope to post some
results.
Chandru Murthi
"Bruce Nichol" <reverse_ecurb@xxxxxxxxxxxxxx> wrote in message
news:27su02p1r8jioahe6i3ugqbumk7ebea194@xxxxxxxxxx
Goo'day, Dawn,
On 8 Mar 2006 07:32:56 -0800, "dawn" <dawnwolthuis@xxxxxxxxx> wrote:
If you want to LIST an
attribute value from an attribute in a file other than the one in your
LIST statement, what are the options for syntax in the dictionary and
the LIST statement?
LIST MY_FILE MY_FILE_ATTRIBUTE THAT_OTHER_FILE_ATTRIBUTE
For example, in UniQuery, you add an I-desc named
THAT_OTHER_FILE_ATTRIBUTE with a TRANS using a value from MY_FILE as a
foreign key to THAT_OTHER_FILE.
In D3, I think you use a TFILE (in an F correlative, or something like
that) and suspect I can find the exact syntax for that.
Are there other ways to do this in various flavors of the Pick Query
language?
I may be totally biased these days but the L-Type dictionary record
from OpenQM is the easiest, most simple way to achieve this - might
also reduce the number of dictionary items floating about....
LIST MY_FILE THAT_OTHER_FILE%THAT_OTHER_FILE_ATTRIBUTE.
All you need is an L-Type record in DICT MY-FILE to work out how to
use the data in MY_FILE to translate into records in THAT_OTHER_FILE,
eg:
If a library application has two files, BOOKS and TITLES where the
record id of BOOKS is formed from the id of the corresponding TITLES
record and the copy number separated by a hyphen, the following link
placed in the dictionary of the BOOKS file could be used to access the
associated TITLES record:
DICT BOOKS TTL
001: L
002: @ID['-', 1, 1]
003: TITLES
Queries based on the BOOKS file could then reference data from the
TITLES file using field names made up from the name of the link
record, a % character and the name of the TITLES field to be accessed.
LIST BOOKS TTL%TITLE TTL%AUTHOR
could be used to print a list of book titles and their authors,
assuming, of course, that DICT TITLES TITLE and AUTHOR exist.....
(Thanks to Ladybridge Systems)
Thanks. --dawnRegards,
Bruce Nichol
Talon Computer Services
ALBURY NSW Australia
http://www.taloncs.com.au
If it ain't broke, fix it until it is....
.
- Follow-Ups:
- Re: Pick query languages compared to SQL
- From: Anthony . Youngman
- Re: Pick query languages compared to SQL
- From: Tom deL
- Re: Pick query languages compared to SQL
- From: B Faux
- Re: Pick query languages compared to SQL
- References:
- Pick query languages compared to SQL
- From: dawn
- Re: Pick query languages compared to SQL
- From: Bruce Nichol
- Pick query languages compared to SQL
- Prev by Date: Re: Pick query languages compared to SQL
- Next by Date: Re: OpenQM vs. Everything Else
- Previous by thread: Re: Pick query languages compared to SQL
- Next by thread: Re: Pick query languages compared to SQL
- Index(es):
Relevant Pages
|