i have below query anyone SQL server master help me this please i am very tensed, i have two column ComboAmmount and TotalPrice, i want if TotalPrice have some price add in ComboAmount . After Add Allmount ComboAmount Show Final Price please check below picture
select CAST( CASE WHEN a.TotalPrice != 0 THEN 1
ELSE 0 END AS bit) as CheckOtherPrice, a.OrderDetailId,a.ItemId,b.ItemCode,b.ItemName,e.GroupName,a.Quantity,a.Price,a.TotalPrice,a.OrderId,isnull(a.ComboId,0)ComboId,
a.ComboGroupId,a.ComboAmount,a.ComboUniqueId,c.ComboName,d.GroupName ComboGroupName,a.OfferMasterId from OrderDetail a
inner join ItemMaster b on a.ItemId=b.ItemId and a.OrderId in (983)
inner join ItemGroup e on b.ItemGroupId=e.ItemGroupId
left join ComboMaster c on a.ComboId = c.ComboId
left join ComboGroup d on a.ComboGroupId = d.GroupId