Weighing Factors in SQL
===

I have a Report where I count quotes across countries and SubRegions. Now I have a number of quotes where the Country is null .

    Table 

Quote Number | Country | Subregion | Quote Count 

12233 | Germany | EMEA | 100 
2223| Blank | EMEA | 3333
3444 | France | EMEA | 200
455454 | Spain | EMEA | 300


Total Quotes Without Null Countries say equals 1000, with 10% related to Germany etc. So Germany weighting factor is 0.1.

So in total I have 3333 quotes where the country field is blank. So  I have been asked to get the quotes for EMEA and just distribute the quotes across the countries like Germany, Spain, France and other EMEA countries using a weighting factor based on the current spread of Quotes and then add the quotes to the counts for the other countries in that Region like EMEA .

So at the moment I am completely confused in terms of how to do this ? Any ideas ?

Help ? Someone ?

Step 1 - Get current weighting factors for all countries in EMEA . In sql ?

Step 2  - Get the quotes count for quotes with no country assigned for EMEA . In sql ?

Step 3 - Take quotes and add x number of quotes to each country based on Weighing Factor. In sql ?



