> CREATE TABLE [dbo].[A](
> [MailPendingGroupID] [int] NOT NULL,
> [Zip] [char](5) NOT NULL,
> [Count] [int] NOT NULL,
> [CountMailed] [int] NOT NULL,
> [AmtMailed] [decimal](9, 3) NOT NULL,
> [dateAdded] [smalldatetime] NOT NULL,
> CONSTRAINT [PK_MailPendingGroupGenSpec] PRIMARY KEY CLUSTERED
> (
> [MailPendingGroupID] ASC,
> [Zip] ASC
> )
> CREATE TABLE [dbo].[B](
> [MailPendingGroupID] [int] NOT NULL,
> [Zip] [char](5) NOT NULL,
> [Cost] [int],
> [dateAdded] [smalldatetime] NOT NULL,
> CONSTRAINT [PK_MailPendingGroupDaily] PRIMARY KEY CLUSTERED
> (
> [MailPendingGroupID] ASC,
> [Zip] ASC
> )
> --
> Vt wrote:
> > hi
> > Can you post Table A and Table b DDL script?
> > Vt
> > Knowledge is power;Share it
> >http://oneplace4sql.blogspot.com
> > "Flomo Togba Kwele" <F@community.nospam> wrote in message
> >news:xn0f74m156b55e000@news.giganews.com...
> > > I have 2 tables, both of which contain a zipcode.
> > > Table A Table B
> > > ZipCode char(5) ZipCode char(5)
> > > I would like to generate something like this:
> > > select distinct(distinct(a.ZipCode) + distinct(b.ZipCode)) ZipCode
> > > but I don't have a clue how to do this. I want a single column combining
> > > the columns from both tables containing distinct values for ZipCode.
> > > TIA, Flomo
> > > --