Sami,
Thanks for answering.  I pasted my code on top of yours and they look the
same except for the where clause.  So, I tried it exactly as you said and it
did the join.  It is apparent that I can not use this command because on the
last page of Tom's book on joins he says, " Unlike the other relational
commands, which always use an Equals comparison between the linking columns.
Join allows you to include a special kind of Where clause that indicates the
comparison operator to use."  Translated: I can not create another table
where customer names are equal and ten digit phone numbers are also.  I
guess I am stuck with a view.

Ultimate objective was to create a table for further processing from a
Corporate Directory and a Network Call Accounting table(s).  There are about
15 other rules to apply just to people that pass rule 1.

I thought that you could be explicit in your where clause.  Guess not.

Phil




> At R> I typed the following:  join c_ctr using c_comp with company using
> nm_comp_id forming c_all where c_comp = nm_comp_id

-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]]On
Behalf Of Sami Aaron
Sent: Thursday, October 25, 2001 10:31 PM
To: [EMAIL PROTECTED]
Subject: Re: Request for Help on Joins


Phil -

I haven't used a JOIN command in many years, but the syntax diagram sample
is:

JOIN prodlocation USING model WITH component USING compid +
FORMING prodcom WHERE =

So, I  think yours should read:
join c_ctr using c_comp with company using nm_comp_id forming c_all where =

See what happens with that!
Sami

-----------------------------------------------------------
Sami Aaron
Software Management Specialists
13214 W. 62nd Terr, #139
Shawnee KS  66216
913-915-1971
http://www.softwaremgmt.com

----- Original Message -----
From: "Phil Nolette (NCS Group, Inc.)" <[EMAIL PROTECTED]>
To: "Rbase-L" <[EMAIL PROTECTED]>
Sent: Thursday, October 25, 2001 8:41 PM
Subject: Request for Help on Joins


> I have checked every possible reference including e-mails, rsyntax, and
even
> a book by Tom Goodell and I am flat begging for help.  It is such a common
> used command on DB2 but I can not get it to work on RBase.
>
> I have two tables that I am trying to join: c_ctr and company.
> Table C_CTR has a whopping three columns (c_comp, c_ctr, and c_ctr_nm.
they
> are all text)
> Table COMPANY has two columns (nm_comp_id and comp_nm.  they are also text
> and both are length 4)
>
> At R> I typed the following:  join c_ctr using c_comp with company using
> nm_comp_id forming c_all where c_comp = nm_comp_id
> = > I consistently get -ERROR- Syntax is incorrect for the comman JOIN
> (2045)
>


> This is a simple join used in debugging.  I have a more complex join in
> queue but if I can not get these two dumb little tables to join, I should
> not go any further.  Do you have to set some setting in order to be able
to
> do joins?
>
> Phil
>


Reply via email to