Hi,
Does your random number really need to be that long ?
SAS will handle an integer up to 16 digits (doc).
If you can work with that, the the following approach will find your nth digit and has the added benefit of generating Pass Thru SQL from PROC SQL (which is what CI Studio will do) for most RDBMS:
MOD({your integer variable}, 10) – this returns the last digit
MOD(FLOOR({your integer variable}/10),10) – this returns the 2nd last digit
MOD(FLOOR({your integer variable}/100),10) – this returns the 3rd last digit
MOD(FLOOR({your integer variable}/1000),10) – this returns the 4th last digit
keep adding a zero to the divisor to get the next "digit".
Regards
James