Error compiling cache code on iris
Hi
I'm trying to migrate a database from cache to iris but i get this from one of the classes on compiling.
ERROR #9101: Global name 'Jobcosting.JobActivityGroupGroupD' for 'IDLocation' is too long, must be no more than 31 characters in length.
> ERROR #5030: An error occurred while compiling class 'Jobcosting.JobActivityGroup'
Comments
Good morning Peter.
I know what the problem is but I googled it anyway, and as usual, Intersystems explains it better than I do.
A global name may be up to 31 characters long (exclusive of the caret character prefix). You can specify global names that are significantly longer, but Caché treats only the first 31 characters as significant.
It's probably worth mentioning that this was always the limit. Prior to IRIS 2020.1 (from memory) any characters after the first 31 were just ignored, so in the above example the global would be truncated to ^Jobcosting.JobActivityGroupGrou. There is now a hard stop in the class compiler that prevents global names longer than the limit as there was the potential for truncated global names to clash.