Report Body Queries

vios15
Member Posts: 43
Dear Expert,
I have 3 tables.
1. Item (eg A123456 with description)
2. Price Category (eg A123456 Cat A Price=$10, A123456 Cat B Price=$20)
3. Item Category (eg Cat A, Cat
In Price Category, there are historical data plus current latest price.
My query is, can I generate a report base on Item No and Price Category of the last record of each Cat, base on the latest date creation? eg. A123456 Cat A Price=$10 (In year 2009) is the latest price but prior to that I have historical data like A123456 Cat A Price=$9 (In year 2008), A123456 Cat A Price=$11(In year 2007).
How could I code in the OnAfterGetRecord, I need only to output the latest of each category?
Thanks for the help.
I have 3 tables.
1. Item (eg A123456 with description)
2. Price Category (eg A123456 Cat A Price=$10, A123456 Cat B Price=$20)
3. Item Category (eg Cat A, Cat

In Price Category, there are historical data plus current latest price.
My query is, can I generate a report base on Item No and Price Category of the last record of each Cat, base on the latest date creation? eg. A123456 Cat A Price=$10 (In year 2009) is the latest price but prior to that I have historical data like A123456 Cat A Price=$9 (In year 2008), A123456 Cat A Price=$11(In year 2007).
How could I code in the OnAfterGetRecord, I need only to output the latest of each category?
Thanks for the help.
0
Comments
-
Hi,
According to my understanding, you need latest price of each category for an Item.
For this you can take the data items Item and Item Category, And in Item Category write the code for getting latest price for this category and item.Thanks & Regards,
Udaykumar Akunuri0 -
Hi UdAkunuri,
Correct me if I am wrong.
Do you mean that I need to use Item as the first table then looks into Item Category table?
But it only print one line, I need the following;
A123456 Cat A $10
A123456 Cat B $9
A123456 Cat C $11
Thanks0 -
Ya, You can take print like this by taking only two data items.
Take the Record variable of the Item Price Category and write the code to pick the latest price with this item and Item category Code....Thanks & Regards,
Udaykumar Akunuri0 -
Hi UdAkunuri,
I will try. Thanks for the help.0
Categories
- All Categories
- 73 General
- 73 Announcements
- 66.6K Microsoft Dynamics NAV
- 18.7K NAV Three Tier
- 38.4K NAV/Navision Classic Client
- 3.6K Navision Attain
- 2.4K Navision Financials
- 116 Navision DOS
- 851 Navision e-Commerce
- 1K NAV Tips & Tricks
- 772 NAV Dutch speaking only
- 617 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 320 Dynamics CRM
- 111 Dynamics GP
- 10 Dynamics SL
- 1.5K Other
- 990 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 35 Design Patterns (General & Best Practices)
- 1 Architectural Patterns
- 10 Design Patterns
- 5 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1.1K General Chat
- 1.6K Website
- 83 Testing
- 1.2K Download section
- 23 How Tos section
- 252 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions