Conversion of Ketoximes to N- substituted amides is known as Beckmann rearrangement. In this rearrangement migration takes place from carbon to nitrogen. The reaction is catalyzed by acidic reagents. The main function of the acidic catalyst is to convert -OH of the oxime into a better leaving group by protonation.
In the Beckmann rearrangement, the alkyl group migrating is the one which is trans to the leaving −OH group: