Join Percona’s Senior Technical Services Engineer, Adamo Tonete as he presents “MongoDB Index Types, How, When and Where Should They be Used?” on Wednesday, July 12, 2017 at 11:00 am PDT / 2:00 pm EDT (UTC-7).
select TOP 100 PERCENT d.OpCo ,d.SUVCVndrNum ,d.VndrNum ,ItemNum ,sum(Cases) [Case Volume] ,sum(FOB) [COGS ($)] ,sum(isnull(FrtPerCase, 0)*Cases) [Freight Cost ($)] ,sum(isnull(LEIPerCase, 0)*Cases) [LEI ($)] ,max(isnull(FrtPerCase, 0)) [Freight Cost / Case ($)] ,max(isnull(LEIPerCase, 0)) [LEI ($) / Case] from tbl_testingfreight d left outer join test.dbo.[OpCo Locations] o on d.OpCo = o.OpCo cross join (select distinct sourcinginitiative from [freightPO-OPCO]) si where SourcedCases > 0 group by d.OpCo ,d.SUVCVndrNum ,d.VndrNum ,ItemNum order by d.OpCo ,ItemNum
Add your voice to the tech community where 5M+ people just like you are talking about what matters.
Join the community of 500,000 technology professionals and ask your questions.