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 TouchToneTommy on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

adding "all' in a view

Status
Not open for further replies.

nikol

Programmer
Apr 12, 2005
126
US
Hi,
I have table with a column which has shows all cities in CA state. Is it possible to add one more row "all cities" in a view.I cant add anything in DB tables. So,I was just wondering can I make a view of all CA state cities & add one more row "all cities" which means all cities in CA.
 
Try something like this:
Code:
select cityname cities from TableA
union all
select 'all cities' cities from TableA

Regards,
AA
 
Or better yet something like this.
Code:
selcet Cityname cities from tablea
union all
select 'All Cities'

Denny
MCSA (2003) / MCDBA (SQL 2000)

--Anything is possible. All it takes is a little research. (Me)

[noevil]
(Not quite so old any more.)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top