Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

one to many table query

Status
Not open for further replies.

n2nuk

IS-IT--Management
Dec 24, 2002
190
GB
Hello there,

What is the expression I need to use to denote the 'many' column on my query, from previous experience i tried the (+) command as used in sqlplus on Oracle.

my query looks like this:
select a.type, l.description, count(a.type)
from
address a, lookup l
where l.code = a.type "a.type is the many column"
and l.code_type = 115
group by a.type, l.description

thanks in anticipation...

Naz
 
Try these operators

*=
Include in the results all the rows from the first table, not just the ones where the joined columns match.
=*
Include in the results all the rows from the second table, not just the ones where the joined columns match.
 
Thanks for that, it worked great.

As I am quite new to Sybase, would you be able to recommend any good Sybase SQL books?

I am using Sybase Adaptive Server Anywhere 7 version 7.0.2.1402

thanks

Naz
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top