Precisely Speaking

Application Support => Prelude Support => Topic started by: precisonline on August 03, 2007, 11:40:41 AM

Title: WARNING: SB+ /GC Can Remove Global Catalog Pointers Used By Production
Post by: precisonline on August 03, 2007, 11:40:41 AM
I've just spent the morning tracking down a weird issue where a change in a development environment removed globally catalogued code from a production environment on the same machine.  Through considerable effort I have determined the cause to the SB+ /GC (Generate Code) feature.

In this particular instance there was a report in development that was also in production.  The production version had code generated via /GC and the development version did not.  When code was later generated in DEV, the cataloged code for the production version went away, and the report in production dropped to TCL with an error every time it was invoked.  Once the catalog pointer was corrected in production, subsequent uses of /GC did not remove the pointer.  It only happened when the code was not previously generated on DEV.

Come to find out, on this version of SB+ (5.3.8) the /GC subroutine includes a call to DELETE.CATALOG.  I'm not entirely clear as to the exact situation under which this verb is invoked, but looking at a dump of the object code for _SB538_GC.CONTROL it's clear that the verb is included somehow.  And to further prove this was the issue, once the DELETE.CATALOG verb was removed from DEV, the problem stopped happening.

In this version of the Activant/Prelude app (19), production programs are catalogued globally by the Prelude BASIC wrapper.  So anything that removes global catalog pointers (as /GC is doing) can inadvertently impact your production environment simply by compiling changes in DEV via /GC.  Therefore:

* If you have both development and production accounts on the same machine, and
*'re using a version of software that catalogs production programs globally, then either:
* ...a) Do not generate code on production without having first done it on your development account, or;
* ...b) Remove the DELETE.CATALOG verb from your VOC in DEV to avoid this from becoming a problem, or;
* ...c) Do not allow SB+ to compile the code that it generates; drop to TCL and manually compile with the BASIC command instead.

If you've ever had any problems with catalog pointers mysteriously disappearing from production - as this client has reported on several occasions - this may very well be something to investigate.