Criminal Note of Appeal Against Sentence:- On 5 November 2012, at Dundee Sheriff Court, the appellant pled guilty on indictment to a contravention of section 52(1)(a) of the Civic Government (Scotland) Act 1982 by taking or permitting to be taken or making indecent photographs or pseudo-photographs of children, and a contravention of section 51A of the Civic Government (Scotland) Act 1982 by having in his possession extreme pornographic images of bestiality. On 11 December 2012, the sheriff imposed a cumulo sentence of 20 months, discounted from 24 months on account of the guilty plea, and an extension period of three years. In terms of section 92(2) and Part 2 of the Sexual Offences Act 2003 the appellant was placed on the register for a period of 10 years from 5 January 2012. Subsequently, the sheriff became aware that section 51A of the Civic Government (Scotland) Act 1982 only came into force for the first time on 28 March 2011. It was accordingly not in force during any part of the period specified in the charge. The sheriff stated in his report to the court that he could not see any other basis on which viewing or possessing images of bestiality could constitute an offence prior to the commencement of that section. Consequently the appellant could neither be convicted nor sentenced for the commission of an offence which had not yet come into being and the sentence imposed was incompetent. It was acknowledged by the sheriff in his report to the court that he ought only to have sentenced the appellant in respect of charge 2 and that had he done so it would have been unlikely that he would have sent the appellant to prison and he would almost certainly have placed the appellant on a community payback order with a condition that he attend the Tay Project for three years. Charge 2 related to substantial amounts of indecent material being recovered from computer equipment in the appellant's home including a large number of images of children aged from 3 to 16 years, 4,176 were at level 1, 26 were at level 2, 28 were at level 3, 63 were at level 4 and 16 were at level 5. In addition, indecent video clips involving children were also recovered, three were at level 1, six were at level 4 and two were at level 5. Here the court considered the definitive guidelines used in England and Wales to determine what the correct sentence should be in respect of charge 2 particularly in light of section 204(2) of the Criminal Procedure (Scotland) Act 1995 applying, the appellant not having previously been sentenced to imprisonment or detention.