To the best of my knowledge "INNER JOIN" is not valid syntax for v6.5. INNER JOIN was added in later versions of RBase try: SELECT P.inj_code FROM patient P , pri_ins I where + P.case#=I.case# + AND P.inj_code = '04' AND I.i_num = '01'
Jim Bentley American Celiac Society [email protected] tel: 1-504-737-3293 ----- Original Message ---- From: John Croson <[email protected]> To: RBASE-L Mailing List <[email protected]> Sent: Mon, May 17, 2010 10:20:25 AM Subject: [RBASE-L] - RE: Syntactically challenged? Rachael, I'm using 6.5, but agree completely with your comment about the pound symbol. I've inherited a bit of a mess, and have been cleaning it up far too long... On 05/17/2010 10:16 AM, Rachael Malberg wrote: > it looks right but that # maybe tripping you up..according to the V8 > help.. > Also, for ODBC compliance, it is not recommended to use the # (pound > sign) symbol in a column name even though R:BASE permits it. > > > ----- Original Message ----- From: "John Croson" > <[email protected]> > To: "RBASE-L Mailing List" <[email protected]> > Sent: Monday, May 17, 2010 9:15 AM > Subject: [RBASE-L] - RE: Syntactically challenged? > > >> Tony, >> >> Thanks for responding, but there is a match. I'm using case#. >> >> >> >> On 05/17/2010 09:04 AM, A.G. IJntema wrote: >>> To me it seems that using a join you should make use of matching >>> columns >>> between the two tables and in your example there is no such match. >>> >>> Have a look at Help inner join, it shows the following example: ON >>> t1.empid >>> = t2.empid >>> >>> Tony >>> >>> >>> -----Original Message----- >>> From: [email protected] [mailto:[email protected]] On Behalf Of John >>> Croson >>> Sent: maandag 17 mei 2010 15:05 >>> To: RBASE-L Mailing List >>> Subject: [RBASE-L] - Syntactically challenged? >>> >>> I'm challenged by this, because I think it should work: >>> >>> SELECT P.inj_code FROM patient P INNER JOIN pri_ins I on >>> P.case#=I.case# >>> WHERE P.inj_code = '04' AND I.i_num = '01' >>> >>> This renders an -ERROR- Syntax is incorrect for the command SELECT >>> [2045] >>> >>> Huh? Isn't this a correct statement? >>> >> >> > > > >

