Skip to main content

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Finance | Project Operations, Human Resources, ...
Answered

How to trace serial number in AX Database

(0) ShareShare
ReportReport
Posted on by 50

I have a Dynamics AX 2012 database only and I am looking in a way to make query to get ( sales order number from serial number)

witch tables should I search in ? 

  • Suggested answer
    nmaenpaa Profile Picture
    101,156 Moderator on at
    RE: How to trace serial number in AX Database

    Yes, actually you can.

  • Ali J Profile Picture
    50 on at
    RE: How to trace serial number in AX Database

    I will try,

    Just one thing to make make sure.

    Can I skip search in InventSerial  as InventDim  contains same info ?

  • Suggested answer
    nmaenpaa Profile Picture
    101,156 Moderator on at
    RE: How to trace serial number in AX Database

    The fact that all tables contain info doesn't mean that there exists a sales order for that Serial id.

    I assume you can figure out what's the problem by looking at the data of the tables.

    Start by one Serial Id, find the corresponding in InventDim, and then see if there's a SalesLine with that InventDimId.

  • Ali J Profile Picture
    50 on at
    RE: How to trace serial number in AX Database

    Thanks for your reply,

    I have tried that using the following query :

    SELECT *

     FROM [dbo].[INVENTSERIAL]

     INNER JOIN [dbo].[InventDim] ON ([dbo].[INVENTSERIAL].[INVENTSERIALID] = [dbo].[InventDim].[INVENTSERIALID])

     INNER JOIN [dbo].[SalesLine] ON ([dbo].[InventDim].[InventDimId] = [dbo].[SalesLine].[InventDimId])

     where [INVENTSERIAL].[INVENTSERIALID]='XXX';

    But I got empty record in return ( despite that all three tables contains info )

  • Verified answer
    nmaenpaa Profile Picture
    101,156 Moderator on at
    RE: How to trace serial number in AX Database

    InventSerial contains the serial numbers.

    Join it with InventDim (on InventSerialId).

    And join InventDim with SalesLine (on InventDimId).

    Sales order number can be found in SalesLine.SalesId.

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,923 Super User 2025 Season 1

#2
Martin Dráb Profile Picture

Martin Dráb 231,788 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156 Moderator

Leaderboard

Product updates

Dynamics 365 release plans