How to dispaly data from all the companines in one report?
muskan_kajal
Member Posts: 4
I am using standard table 405(Change log entry) to display all modifications done for aay company by any user and for one functionality. And I am using one customized table for specifying users.
I have made a Report for displaying records form Table 405 for all the users specified in my customized table.
Now my client wants that my report should not display company specific data rather he wants me to display data for all the comapnines together when he runs that report form any comapny.
for eg I have two companies A and B. So he wants that when I run my report from company A it should display data from comapny B also and vice versa.
I have made a Report for displaying records form Table 405 for all the users specified in my customized table.
Now my client wants that my report should not display company specific data rather he wants me to display data for all the comapnines together when he runs that report form any comapny.
for eg I have two companies A and B. So he wants that when I run my report from company A it should display data from comapny B also and vice versa.
0
Comments
-
You can do this:
create temporary table
set company for record with record.CHANGECOMPANY
copy all records to temporary table
this do for all companies
and than print/show it0 -
Look at the statement "CHANGECOMPANY".
I think of three ways:
1) extra dataitem based on company table
This way, you're looping the company table. In the OnAfterGetRecord of that dataitem, you can do a CHANGECOMPANY of the Change Log Entry.
Disadvantage is that you won't be able to group the data in a decent way. The report is grouped on company level.
2) same as above, but filling a temp table (based also on the Change Log Entry). After that, print your report based on that temp table. Grouping is flexible in this way.
You can do all this in one report.
3) Make your table "DataPerCompany" = No and my be add a field and fill it with the company name (if needed). I don't know how this is going to end up, but it seems feasable... .
Disadvantage is that users in different companies is going to lock each other because they're all working in the same table.
I would go for option 2.0 -
Or there is next way:
If you are on SQL, you can create View as union of all tables for all companies and add it into NAV as LinkedObject. Than you can create the report over this... (in the view you can add one field with name of the company to have unique identification...)0
Categories
- All Categories
- 75 General
- 75 Announcements
- 66.7K Microsoft Dynamics NAV
- 18.8K 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
- 611 NAV Courses, Exams & Certification
- 2K Microsoft Dynamics-Other
- 1.5K Dynamics AX
- 253 Dynamics CRM
- 103 Dynamics GP
- 6 Dynamics SL
- 1.5K Other
- 991 SQL General
- 383 SQL Performance
- 34 SQL Tips & Tricks
- 28 Design Patterns (General & Best Practices)
- Architectural Patterns
- 9 Design Patterns
- 4 Implementation Patterns
- 53 3rd Party Products, Services & Events
- 1.6K General
- 1K General Chat
- 1.6K Website
- 77 Testing
- 1.2K Download section
- 23 How Tos section
- 249 Feedback
- 12 NAV TechDays 2013 Sessions
- 13 NAV TechDays 2012 Sessions

