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

Announcements

News and Announcements icon
Community site session details

Community site session details

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

Why does quantity query using Purchase Receipts differ from Transactions Amount History

(0) ShareShare
ReportReport
Posted on by 75,852 Moderator

Why would these two script come up with different numbers? They differ by exactly 2,000.

SELECT SUM(TRXQTY) FROM dbo.[IV30300] WHERE ITEMNMBR='PARTNUMBER' AND TRXLOCTN = 'MAIN'

SELECT SUM(QTYRECVD-QTYSOLD) FROM dbo.[IV10200] WHERE ITEMNMBR='PARTNUMBER' AND TRXLOCTN = 'MAIN'

The GP Purchase Receipts report agrees with the second script and the IV Stock Status Report comes up with a number that is close but not exact.

I need to add inventory valuation numbers to an SSRS report so I need to know which tables to use.

Categories:
I have the same question (0)
  • Hokuminaria Profile Picture
    2,950 on at

    Hell Richard,

    My guess is that something is missing from the IV30300 table. that is in the IV10201. This could be caused by an Interruption or hjstory turned off for the item at some point.

    You would need to look at the data for these two table to determine why your scripts are giving you different results.

    If you can, i would look at using the SEE30303 table. This table should capture all activity whether history is on or not.

    One other thing to look at regarding the IV30303. You could have transfers. Be sure you are including sites that would have been transferred to/from. The transfer would have the original site listed and could be why your scripts are returning different results.

    I hope this helps!

    Thank you!

    Brandon Jarrett | Microsoft Support Engineer.

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

Season of Sharing Community Challenge Launch!

Jump in, show your community spirit, and win prizes!

Women in Power Builds Momentum

Expanding mentorship, skilling, and AI innovation

Congratulations to the May Top 10 Community Leaders

These are the community rock stars!

Leaderboard > Finance | Project Operations, Human Resources, AX, GP, SL

#1
Abhilash Warrier Profile Picture

Abhilash Warrier 681 Super User 2026 Season 1

#2
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 598 Super User 2026 Season 1

#3
Giorgio Bonacorsi Profile Picture

Giorgio Bonacorsi 579

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans