Globals and organization

Given that global fields are stored as values within the Servoy repository, it makes sense that you’ll end up with a large number of global fields if you develop any more than one solution in one copy of Developer.

I have a suggestion that globals, as shown in the globals tab of Define Data Providers, only show on a per table basis. Meaning you select a table and the globals tab updates to show only those globals used in the current solution being opened and as defined by which databases use them.

I know you can’t determine which tables actually associate to which globals on a per solution basis, but you can allow the developer to select a global, then make a manual association to a table. By virtue of the fact that a given solution might be open this secondary association would be made automatically.

Creation: If you attempt to create a global with the same name as an existing global (not shown, but hidden), used by another solution, then a dialog prompt would say “This name has been used by another table/solution. Please choose another name”.

Deletion: If a global is to be deleted then the prompt “This global may be used by more than one solution, are you positive you want to delete it!!!”

This would help organize a solution and the globals. Knowing which resources are used by which solution is helpful when multiple solutions are being developed.

Matt, do I understand correct that you assume that globals of one solution will be visible in the other?

Because this is not the case. Not for different solutions on different databases and not for different solutions on the same database.

Or do I mis-interpret your posting?

Ciao

IT2BE:
Matt, do I understand correct that you assume that globals of one solution will be visible in the other?

Because this is not the case. Not for different solutions on different databases and not for different solutions on the same database.

Or do I mis-interpret your posting?

Ciao

You understood me correctly. I was too fast to post. You’ll get a kick out of this one.

Because I am so consistent in my naming, when moving from solution to solution I kept seeing the exact same fields.

I had exactly 4 globals in each of 2 solutions and they were named the same. I assumed that the globals were shared amongst solutions.

I then, an hour later, went to a third solution and found the globals were solution independant.

Sorry! My mistake. :oops:

Disregard this post.

We’re thinking of adding a description field to globals.
(not really high prio at this moment)

No Matt, I didn’t get a kick out of this one, just a smile of recognition :D