Skip to main content

Notifications

Announcements

No record found.

Finance | Project Operations, Human Resources, ...
Suggested answer

How can I set up Database log for Number Sequence code ?

Posted on by 410

Hi

I would like set up Database log for number sequence code.

But I can't find the table for this field ?

Can you suggest for this ?

pastedimage1623299589821v1.png

  • Tanyaboon Profile Picture
    Tanyaboon 410 on at
    RE: How can I set up Database log for Number Sequence code ?

    Thank you all

    The table is Number sequence group reference.

  • Suggested answer
    Ludwig Reinhard Profile Picture
    Ludwig Reinhard Microsoft Employee on at
    RE: How can I set up Database log for Number Sequence code ?

    Hi Tanyaboon,

    Can you search for the element 'Not specified' and there the number sequence section where you have multiple tables available for selection?

    I don't know which one might be the right one but you could check and test this yourself in a demo/test environment.

    Best regards,

    Ludwig

  • OsmanIstanbul Profile Picture
    OsmanIstanbul 2,803 on at
    RE: How can I set up Database log for Number Sequence code ?

    ++ just change the table num on the job.

  • Suggested answer
    OsmanIstanbul Profile Picture
    OsmanIstanbul 2,803 on at
    RE: How can I set up Database log for Number Sequence code ?

    Hi,

    You can use below job to setup  database log for your table instead of find it out manually.

    static void AV_addTableToDatabaseLogSetup(Args _args)

    {

       databaselog     databaselog;

       TableId         tableId = tableNum(NumberSequenceReference);

       select firstonly databaselog where databaselog.logTable == tableId    &&

           databaselog.logType == databaselogType::Insert;

       if (databaselog.RecId == 0)

       {

           databaselog.domainId = 'Admin';

           databaselog.logType  = databaselogType::Insert;

           databaselog.logTable = tableId;

           databaselog.logField = 0;

           databaselog.insert();

       }

       select firstonly databaselog where databaselog.logTable == tableId    &&

           databaselog.logType == databaselogType::Update;

       if (databaselog.RecId == 0)

       {

           databaselog.domainId = 'Admin';

           databaselog.logType  = databaselogType::Update;

           databaselog.logTable = tableId;

           databaselog.logField = 0;

           databaselog.insert();

       }

       select firstonly databaselog where databaselog.logTable == tableId    &&

           databaselog.logType == databaselogType::Delete;

       if (databaselog.RecId == 0)

       {

           databaselog.domainId = 'Admin';

           databaselog.logType  = databaselogType::Delete;

           databaselog.logTable = tableId;

           databaselog.logField = 0;

           databaselog.insert();

       }

       select firstonly databaselog where databaselog.logTable == tableId    &&

           databaselog.logType == databaselogType::RenameKey;

       if (databaselog.RecId == 0)

       {

           databaselog.domainId = 'Admin';

           databaselog.logType  = databaselogType::RenameKey;

           databaselog.logTable = tableId;

           databaselog.logField = 0;

           databaselog.insert();

       }

       SysFlushDatabaseLogSetup::main();

    }

    Regards

  • Suggested answer
    André Arnaud de Calavon Profile Picture
    André Arnaud de Cal... 291,269 Super User 2024 Season 2 on at
    RE: How can I set up Database log for Number Sequence code ?

    Hi Tanyaboon,

    The table used is NumberSequenceReference. It is part of the Organization administration area.

  • Suggested answer
    Ludwig Reinhard Profile Picture
    Ludwig Reinhard Microsoft Employee on at
    RE: AX2012R3CU11: How can I set up Database log for Number Sequence code ?

    Hi,

    Looks as if you are in the AR parameter form. Have you tried searching through the related tables and fields in the database log configuration form?

    Best regards,

    Ludwig

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

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,269 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,198 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Product updates

Dynamics 365 release plans