Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
kwikwisi
Constraint Violating Yak Guru
283 Posts |
Posted - 2008-08-01 : 04:35:44
|
I want only records from rtb but i'm getting also from CoPlz help .CREATE PROCEDURE [dbo].[d_tt]@rid int ASselect r.CustomerID as cid,c.Name as cname,s.Name as ---from rtb r left join Sr s on r.SID = s.SID left join Co c on r.CID = c.CIDleft join Rc rc on r.rs=rc.rswhere r.SID=@rid order by r.CustomerIDGO |
|
pootle_flump
1064 Posts |
Posted - 2008-08-01 : 04:47:37
|
Sorry - doesn't make sense - you reference columns from Co in your select statement. What do you mean you don't want records from Co? |
 |
|
elancaster
A very urgent SQL Yakette
1208 Posts |
Posted - 2008-08-01 : 04:48:33
|
eh? you're selecting records from Co. if you don't want them don't select themEm |
 |
|
kwikwisi
Constraint Violating Yak Guru
283 Posts |
Posted - 2008-08-01 : 04:56:47
|
I need only name from Co where Co.ID=rtb.IDWhat's wrong my query?quote: Originally posted by elancaster eh? you're selecting records from Co. if you don't want them don't select themEm
|
 |
|
kwikwisi
Constraint Violating Yak Guru
283 Posts |
Posted - 2008-08-01 : 05:03:13
|
Can anyone suggest me?quote: Originally posted by pootle_flump Sorry - doesn't make sense - you reference columns from Co in your select statement. What do you mean you don't want records from Co?
|
 |
|
pootle_flump
1064 Posts |
Posted - 2008-08-01 : 06:02:42
|
http://weblogs.sqlteam.com/brettk/archive/2005/05/25/5276.aspx |
 |
|
|
|
|