Engine and gearbox codes along with lots of other information (paint code for a start) are on a sticky label that should be under the carpet in the boot (may be in the wheel well) and also in the service book.
sample
http://www.germanautoparts.com/linked/vwchassis.html
Another one
and again (boot
sticker)
The meanings of some of the codes; (taken from my build sheet, with serial numbers anonymised)
Code:
G123 24-5 697289 EG
VSS ZZZ 1M Z 2B123456 VIN code; Chassis number 2B123456
1M28 24 1M2824 is the complete model code
TOLEDO TDI 8 SIGNA Model designation for 1M2824 in MY02
81 MNO C5M 81 = engine power in KW
ASV EGS Engine code and Gearbox code
LS5N ---- ---- KU Paint No and interior code
After this you get a series of 3-character Option codes which indicate what options were installed at the factory. The 3-character option codes are common across all VAG vehicles and the spreadsheet summarising them is nearly a gigabyte in size. There was a short list, for codes relevant to Octavia's, published on the Briskoda forum.