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.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 Disregard -- Resp. to prev. question

Author  Topic 

drsloat
Starting Member

45 Posts

Posted - 2002-05-24 : 13:36:22
I hard coded in the customerID=12 and currencyID=1 but you can pass
these as parameters


Select t1.ServiceLevelID, t1.currencyID, IsNull(tm.CustomerID,0) as 'customerID',
IsNull(tm.minCharge,t1.defaultMinCharge) as 'minCharge'
From
(
Select ServiceLevelID, 12 as 'CustomerID', minCharge as 'defaultMinCharge', currencyID
From tbl_Costs_MinimumCharges
Where customerID = 0 and currencyID=1
) as t1 Left Outer Join tbl_Costs_MinimumCharges tm
on (t1.ServiceLevelID = tm.ServiceLevelID and t1.CustomerID = tm.CustomerID and t1.currencyID = tm.currencyID)



Edited by - drsloat on 05/24/2002 14:02:35

drsloat
Starting Member

45 Posts

Posted - 2002-05-24 : 13:39:10
Sorry... This is a reply to another topic, but I accidentally hit "new topic"

This is the original thread:
http://www.sqlteam.com/forums/topic.asp?TOPIC_ID=16216

Go to Top of Page
   

- Advertisement -