Is Production order still busy/active, can I filter on this?

ajhvdb
Member Posts: 672
I'd like to show which production orders are "busy".
Most PO's are busy for about 3 weeks. For example; Start date = 1-1-09, End date 21-1-09
Is there a filter for this? I'd like to ask "Which PO's are still busy on the following days; 7-1-09..12-1-09"
It is working now by using the table "date" but with a key and a filter it will be much faster. Now i'm looping through all records. Thx.
Most PO's are busy for about 3 weeks. For example; Start date = 1-1-09, End date 21-1-09
Is there a filter for this? I'd like to ask "Which PO's are still busy on the following days; 7-1-09..12-1-09"
It is working now by using the table "date" but with a key and a filter it will be much faster. Now i'm looping through all records. Thx.
0
Comments
-
-
u can use the compination of
setfilter("Starting Date",'<=%1',SelectedDay);
setfilter("Ending Date",'>=%1',SelectedDay);
and also the other Date filter combinations or you set the the filter on Date Rec with filtergroup(2). Then you loop throught all released Prod. Orders and store all Prod. order which are in the filter in a temp Table and show them.
fast exampleDateRec.filtergroup(2); DateRec.setrange("Period Type",DateRec."Period type"::Day); DateRec.setrange("Period Start",StartDateVar,EndDateVar); DateRec.filtergroup(0); RelProdOrders.reset; //some filtercriterias RelProdOrders.setrange(SomeFields); if RelProdOrders.findset(false,false) then begin repeat //here filter <=%1 / >=%2 and >=%1 / <=%2 and so on .... for "Starting Date" and "Ending Date" DateRec.setfilter("Period Start",'<=%1&>=%2',RelProdOrders."Starting Date",RelProdOrders."Endinging Date"); if not DateRec.isempty then begin TempRelProdOrder.init; TempRelProdOrder.Fields := RelProdOrder.Field; TempRelProdOrder.insert; end; untli RelProdOrders.next = 0; end;
Do you make it right, it works too!0 -
Thx for the example. Yes I'm using the daterec too. This does work but I need to loop thru all the PO records.
I'd like to set filters on the PO and only get the PO records, busy/active during this filter period (010109..210109). It is possible if I use 1 day in the filter but from/untill doesn't work.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