Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

ENUM values missing in SRSANALYSISENUMS Table

(0) ShareShare
ReportReport
Posted on by 285

I populated SRSANALYSISENUMS Table by using each of following ways, but some enum that are created in cus layer are missing in this Table after pipulating the Table.

(http://gerryhubi.wordpress.com/2010/03/16/ssas-tips-enum-dimensions-in-ax2009-cubes/)

·         Run the method “populateSRSAnalysisEnums" of the class "BIGenerator".

·         Go to Tools>Business Intelligence Tools>OLAP Administration. Check the “Update BI Data”, and click “Update Databases” button.

Any pointers on this is appreciated.

Thanks

*This post is locked for comments

  • Bart VDS Profile Picture
    Bart VDS 227 on at
    RE: ENUM values missing in SRSANALYSISENUMS Table

    Guypacome, thanks for sharing, your code is good and it still works in AX2012. I find it more practical than the SQL approach described on Abra Axapta, although that was a very interesting read. 

    A bit at the end is missing, it should be:

            ttscommit;
          }
          tnChildValues = RootNodeIteratorValues.next();
        }
        tnChild = RootNodeIterator.next(); 
      }
    }
    

    Also, for the macro's to work correctly, you need these two lines after your declarations:

        #AOT
        #Properties
  • Suggested answer
    Re: ENUM values missing in SRSANALYSISENUMS Table

    If you are using AX 2012: abraaxapta.blogspot.com/.../accessing-enum-labels-from-outside-ax.html

    If you are using 4.0 or 2009: abraaxapta.blogspot.com/.../missing-enums-in-srsanalysisenums.html

  • Guypacome Gbelai Profile Picture
    Guypacome Gbelai 70 on at
    Re: ENUM values missing in SRSANALYSISENUMS Table

    I had the same issue. I fixed it by writting a new method. The code don't check the perspective node but only the baseEnum node.
    see the code below:

    TreeNode tnEnums;

    TreeNode tnChild;

    TreeNode tnChildValues;

    TreeNodeIterator RootNodeIterator;

    TreeNodeIterator RootNodeIteratorValues;

    SRSAnalysisEnums SRSAnalysisEnums;

     

     

     

    int

    objID;

     

     

     

    int

    i;

    Set languageIdSet =

     

     

    new

    Set(Types::String);

    SetEnumerator languageIdEnumerator;

    LanguageId languageId;

    BIUdmTranslations translations;

    ;

     

     

     

    // initialize the translation table

    BIUdmTranslations::initialize();

     

     

     

    while select LanguageId, Generate from translations where translations.Generate ==

    1

    {

    languageIdSet.add(translations.LanguageId);

    }

    tnEnums = TreeNode::findNode(#BaseEnumsPath);

    RootNodeIterator = tnEnums.AOTiterator();

    tnChild = RootNodeIterator.next();

     

     

     

    delete_from

    SRSAnalysisEnums;

     

     

     

    while

    (tnChild)

    {

    objID = tnChild.applObjectId();

    RootNodeIteratorValues = tnChild.AOTiterator();

    tnChildValues = RootNodeIteratorValues.next();

     

     

     

    while

    (tnChildValues)

    {

    i = tnChildValues.AOTgetProperty(#PropertyEnumValue);

    languageIdEnumerator = languageIdSet.getEnumerator();

     

     

     

    while

    (languageIdEnumerator.moveNext())

    {

    languageId = languageIdEnumerator.current();

     

     

     

    ttsbegin

    ;

    SRSAnalysisEnums.clear();

    SRSAnalysisEnums.EnumName = tnChild.AOTgetProperty(#PropertyName);

    SRSAnalysisEnums.EnumItemValue = i;

    SRSAnalysisEnums.EnumItemLabel = sysLabel::labelId2String(tnChildValues.AOTgetProperty(#PropertyLabel), languageId);

    SRSAnalysisEnums.LanguageId = languageId;

    SRSAnalysisEnums.EnumItemName = tnChildValues.AOTgetProperty(#PropertyName);

    SRSAnalysisEnums.insert();

     

     

     

    ttscommit

    ;

  • Verified answer
    KyleLeBarre Profile Picture
    KyleLeBarre 745 on at
    Re: ENUM values missing in SRSANALYSISENUMS Table

    I figure this has been taken care of, but if anybody else has this issue, you need to add the table that contains the field with the enum into a Perspective in the AOT. You will then need to run the method or do the "Update databases" option again. The "populateSRSAnalysisEnums" method only loops through the child nodes of the perspective, it does not look at every enum in the AOT.

    I'd recommend creating a new perspective to contain all of the tables that you need enums for.

  • DJB Profile Picture
    DJB 5 on at
    Re: ENUM values missing in SRSANALYSISENUMS Table

    Hi Abhijeet,

    Did you resolve this issue?  I am seeing the same problem.

    Thanks

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Daivat Vartak – Community Spotlight

We are honored to recognize Daivat Vartak as our March 2025 Community…

Announcing Our 2025 Season 1 Super Users!

A new season of Super Users has arrived, and we are so grateful for the daily…

Kudos to the February Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 292,516 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 231,432 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans