In the 2012 Olympics, individual Scottish competitors won two gold medals (Andy Murray and Sir Chris Hoy) and one silver (swimmer Michael Jamieson). Ten medals went to UK teams that included Scottish athletes (five gold, three silver, and two bronze) – and how they would have fared as separate Scottish and Rest of UK teams is unclear. Athletes from the rest of the UK won 22 golds, 13 silvers, and 17 bronze medals without any Scottish athletes being involved.
If you exclude all mixed team medals, Rest of UK would have placed fourth in the medal table (slipping one place, behind Russia), while Scotland would have placed 36th, just behind Norway.