44
Instead of using prefixes and suffixes in object names limited to 30 characters anyway, it would probably be better to use namespaces as known from other professional programming languages.
Category: Development
STATUS DETAILS
Needs Votes

Comments

K

If you want to reference objects out of your own module you must do this with including the namespace.

Your namespace will be configured in the app.json and can it PascalNaming structure.

You have a namespace fore your company (This now your affix), and one for your module.


So if you want to access the "Sales Line" table from your module you must reference it with

Microsoft.BaseApplication."Sales Line".


This will solve al lot in the names of the objects, because we have now only 30 characters and in these 30 characters we must fit our company affix and our module affix. This resolve quickly in unreadable name, and in a modern development environment the name must tel you wat you expect with out a dictionary.


I realize that this is big change, but one for the future and it aligns also with .net system.

Category: Development

K

Adding link to old GitHub topic on the same for reference/comments
https://github.com/microsoft/AL/issues/1517

Category: Development

K

This is great idea! Please, implement it.

Category: Development

K

To add one more idea to my previous comment:
- Use App Name from App.json as namespace

Category: Development

K

Namespaces would definitely be better solution then increasing object name size. Microsoft guys pointed many times that increasing field and object names would create lot of downstream issues. On the other hand, namespaces could be implemented without big changes in the underlying system:
- Namespace would be defined in extension's App.json;
- Base application namespace would be empty string;
- Namespace would not be contained inside field or object definitions in AL;
- Internally, when managing symbols, namespaces would be present in all object, field, procedure and variable names, and visible to dependent apps in that form (Namespace.Name);
- SQL tables would keep table/field names as they are now, Affixes were not introduced because of SQL problems (app GUID in table names solves the issue);

Category: Development