web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

Query data when create PO direct delivery from Sales order in AX 2012

(1) ShareShare
ReportReport
Posted on by 237

Dear Experts,

I want to create SQL query to get data sales order(SO, packing slip, invoice), purchase order(PO, product receipt, invoice) when I create PO direct delivery from sales order.

Get information:

SalesId, ItemId, Sales Qty, Sales Amount, PurchId, ItemId, Purch Qty, Purch Amount, Packing slip number, Product receipt number, Delivery date, Cust Invoice Id, Cust Invoice Qty, Cust Invoice Amount, Vendor Invoice Id, Vendor Invoice Qty, Vendor Invoice Amount.

Could you please advice me?

Thanks in advance.

*This post is locked for comments

I have the same question (0)
  • Verified answer
    Rustem Galiamov Profile Picture
    8,072 on at
    RE: Query data when create PO direct delivery from Sales order in AX 2012

    Hi Sacramento!

    To achieve this you need to use SalesTable, SalesLine, PurchTable, PurchLine, CustPackingSlipJour, VendPackingSlipJour,  CustInvoiceJour, CustInvoiceTrans, VendInvoiceJour, VendInvoiceTrans tables.

    When you create PO from SO, the SO and PO are linked by lines (InventRefId and InventRefTransId fields).

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Mansi Soni – Community Spotlight

We are honored to recognize Mansi Soni as our August 2025 Community…

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

#1
Syed Haris Shah Profile Picture

Syed Haris Shah 9

#2
Mea_ Profile Picture

Mea_ 4

#3
KP-31070522-0 Profile Picture

KP-31070522-0 3

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans