Slice time according to groups

Hello,
I have oracle 9i DB, I have to divide time according to below time span
From Month To Month EstLoad FromTime ToTime
5     8     5     02:00     13:00
5     8     20     13:01     17:00
the above data is stored in Table I want to calculate the EstLoad based on above time span for instance I have interruption which starts at 12:45 and End at 13:30 so in this case we have two slices 12:45 - 13:00 and 13:01 - 13:30, I want to write a query for this slicing of time is it possible with query because I don't want to hard code start and end time in report I want to pass it from table.
Thanks and Regards, Khawar.

Hi Dear,
It works great, although this query looks simple but still I am trying to understand how it works, Thanks again.
Regards, Khawar.
Hi Rob,
I found this query does not works some time as expected I tried to fix it but no success
just take a look at table EST_LOAD
CREATE TABLE EST_LOAD
  FROM_MONTH     NUMBER,
  TO_MONTH       NUMBER,
  LOAD_KW        NUMBER                         DEFAULT 0,
  FROM_TIME      VARCHAR2(20 BYTE),
  TO_TIME        VARCHAR2(20 BYTE),
  DISTRICT_CODE  VARCHAR2(10 BYTE)
ALTER TABLE EST_LOAD ADD (
  CONSTRAINT EST_LOAD_PK
PRIMARY KEY
(FROM_MONTH, TO_MONTH, FROM_TIME, TO_TIME, DISTRICT_CODE)data for table t is
Insert into EST_LOAD  (FROM_MONTH, TO_MONTH, LOAD_KW, FROM_TIME, TO_TIME,     DISTRICT_CODE)
Values  (10, 12, 0.8, '00:00', '23:59',     'BBALI');
Insert into EST_LOAD   (FROM_MONTH, TO_MONTH, LOAD_KW, FROM_TIME, TO_TIME,     DISTRICT_CODE)
Values   (5, 9, 0.8, '17:01', '22:00',     'BBALI');
Insert into EST_LOAD   (FROM_MONTH, TO_MONTH, LOAD_KW, FROM_TIME, TO_TIME,     DISTRICT_CODE)
Values   (5, 9, 0.8, '02:01', '13:00',     'BBALI');
Insert into EST_LOAD   (FROM_MONTH, TO_MONTH, LOAD_KW, FROM_TIME, TO_TIME,     DISTRICT_CODE)
Values   (5, 9, 1.6, '00:00', '02:00',     'BBALI');
Insert into EST_LOAD   (FROM_MONTH, TO_MONTH, LOAD_KW, FROM_TIME, TO_TIME,     DISTRICT_CODE)
Values   (5, 9, 1.6, '22:00', '23:59',     'BBALI');
Insert into EST_LOAD   (FROM_MONTH, TO_MONTH, LOAD_KW, FROM_TIME, TO_TIME,     DISTRICT_CODE)
Values   (8, 9, 2.4, '13:01', '17:00',     'BBALI');
Insert into EST_LOAD   (FROM_MONTH, TO_MONTH, LOAD_KW, FROM_TIME, TO_TIME,     DISTRICT_CODE)
Values   (5, 7, 3.2, '13:01', '17:00',     'BBALI');
Insert into EST_LOAD   (FROM_MONTH, TO_MONTH, LOAD_KW, FROM_TIME, TO_TIME,     DISTRICT_CODE)
Values   (1, 4, 0.8, '00:00', '23:59',     'BBALI');create table INTERP_DETAIL stmt
CREATE TABLE INTERP_DETAIL
  REF_NO         NUMBER(5)                      NOT NULL,
  INC_TYPE_CODE  VARCHAR2(2 BYTE)               NOT NULL,
  FEEDER_CODE    VARCHAR2(8 BYTE)               NOT NULL,
  VOL_LEVEL      VARCHAR2(3 BYTE),
  START_DT_TIME  DATE,
  GRID_CODE      VARCHAR2(3 BYTE)               NOT NULL,
  END_DT_TIME    DATE,
  LOAD_AMP       NUMBER(10,3)
ALTER TABLE INTERP_DETAIL ADD (
  CONSTRAINT INTERP_DETAIL_PK
PRIMARY KEY
(REF_NO, INC_TYPE_CODE, GRID_CODE, FEEDER_CODE, START_DT_TIME, END_DT_TIME)data for INTERP_DETAIL table
Insert into INTERP_DETAIL
   (REF_NO, INC_TYPE_CODE, FEEDER_CODE, VOL_LEVEL, START_DT_TIME,     GRID_CODE, END_DT_TIME, LOAD_AMP)
Values   (2116, 'UN', 'RUSG11L5', '33', TO_DATE('09/09/2008 23:43:00', 'MM/DD/YYYY HH24:MI:SS'),     'RUS', TO_DATE('09/10/2008 01:04:00', 'MM/DD/YYYY HH24:MI:SS'), 14);
Insert into INTERP_DETAIL   (REF_NO, INC_TYPE_CODE, FEEDER_CODE, VOL_LEVEL, START_DT_TIME,     GRID_CODE, END_DT_TIME, LOAD_AMP)
Values   (2116, 'UN', 'RUSG9L5', '33', TO_DATE('09/09/2008 23:43:00', 'MM/DD/YYYY HH24:MI:SS'),     'RUS', TO_DATE('09/10/2008 00:22:00', 'MM/DD/YYYY HH24:MI:SS'), 154);
Insert into INTERP_DETAIL   (REF_NO, INC_TYPE_CODE, FEEDER_CODE, VOL_LEVEL, START_DT_TIME,     GRID_CODE, END_DT_TIME, LOAD_AMP)
Values   (2116, 'UN', 'RUSG7L5', '33', TO_DATE('09/09/2008 23:43:00', 'MM/DD/YYYY HH24:MI:SS'),     'RUS', TO_DATE('09/10/2008 00:22:00', 'MM/DD/YYYY HH24:MI:SS'), 67);
Insert into INTERP_DETAIL   (REF_NO, INC_TYPE_CODE, FEEDER_CODE, VOL_LEVEL, START_DT_TIME,     GRID_CODE, END_DT_TIME, LOAD_AMP)
Values   (2116, 'UN', 'RUSG5L5', '33', TO_DATE('09/09/2008 23:43:00', 'MM/DD/YYYY HH24:MI:SS'),     'RUS', TO_DATE('09/10/2008 00:22:00', 'MM/DD/YYYY HH24:MI:SS'), 78);
Insert into INTERP_DETAIL   (REF_NO, INC_TYPE_CODE, FEEDER_CODE, VOL_LEVEL, START_DT_TIME,     GRID_CODE, END_DT_TIME, LOAD_AMP)
Values   (2116, 'UN', 'RUSG3L5', '33', TO_DATE('09/09/2008 23:43:00', 'MM/DD/YYYY HH24:MI:SS'),     'RUS', TO_DATE('09/10/2008 00:22:00', 'MM/DD/YYYY HH24:MI:SS'), 95);
Insert into INTERP_DETAIL   (REF_NO, INC_TYPE_CODE, FEEDER_CODE, VOL_LEVEL, START_DT_TIME,     GRID_CODE, END_DT_TIME, LOAD_AMP)
Values   (2116, 'UN', 'RUSG1L5', '33', TO_DATE('09/09/2008 23:43:00', 'MM/DD/YYYY HH24:MI:SS'),     'RUS', TO_DATE('09/10/2008 00:22:00', 'MM/DD/YYYY HH24:MI:SS'), 49);
Insert into INTERP_DETAIL   (REF_NO, INC_TYPE_CODE, FEEDER_CODE, VOL_LEVEL, START_DT_TIME,     GRID_CODE, END_DT_TIME, LOAD_AMP)
Values   (2116, 'UN', 'RUSG12L5', '33', TO_DATE('09/09/2008 23:43:00', 'MM/DD/YYYY HH24:MI:SS'),     'RUS', TO_DATE('09/10/2008 00:22:00', 'MM/DD/YYYY HH24:MI:SS'), 51);
Insert into INTERP_DETAIL   (REF_NO, INC_TYPE_CODE, FEEDER_CODE, VOL_LEVEL, START_DT_TIME,     GRID_CODE, END_DT_TIME, LOAD_AMP)
Values   (2116, 'UN', 'RUSG10L5', '33', TO_DATE('09/09/2008 23:43:00', 'MM/DD/YYYY HH24:MI:SS'),     'RUS', TO_DATE('09/10/2008 00:22:00', 'MM/DD/YYYY HH24:MI:SS'), 84);
Insert into INTERP_DETAIL   (REF_NO, INC_TYPE_CODE, FEEDER_CODE, VOL_LEVEL, START_DT_TIME,     GRID_CODE, END_DT_TIME, LOAD_AMP)
Values   (2116, 'UN', 'RUSG8L5', '33', TO_DATE('09/09/2008 23:43:00', 'MM/DD/YYYY HH24:MI:SS'),     'RUS', TO_DATE('09/10/2008 00:23:00', 'MM/DD/YYYY HH24:MI:SS'), 72);
Insert into INTERP_DETAIL   (REF_NO, INC_TYPE_CODE, FEEDER_CODE, VOL_LEVEL, START_DT_TIME,     GRID_CODE, END_DT_TIME, LOAD_AMP)
Values   (2116, 'UN', 'RUSG6L5', '33', TO_DATE('09/09/2008 23:43:00', 'MM/DD/YYYY HH24:MI:SS'),     'RUS', TO_DATE('09/10/2008 00:23:00', 'MM/DD/YYYY HH24:MI:SS'), 51);
Insert into INTERP_DETAIL   (REF_NO, INC_TYPE_CODE, FEEDER_CODE, VOL_LEVEL, START_DT_TIME,     GRID_CODE, END_DT_TIME, LOAD_AMP)
Values   (2116, 'UN', 'RUSG4L5', '33', TO_DATE('09/09/2008 23:43:00', 'MM/DD/YYYY HH24:MI:SS'),     'RUS', TO_DATE('09/10/2008 00:23:00', 'MM/DD/YYYY HH24:MI:SS'), 159);
Insert into INTERP_DETAIL   (REF_NO, INC_TYPE_CODE, FEEDER_CODE, VOL_LEVEL, START_DT_TIME,     GRID_CODE, END_DT_TIME, LOAD_AMP)
Values   (2116, 'UN', 'RUSG2L5', '33', TO_DATE('09/09/2008 23:43:00', 'MM/DD/YYYY HH24:MI:SS'),     'RUS', TO_DATE('09/10/2008 00:23:00', 'MM/DD/YYYY HH24:MI:SS'), 160);
Insert into INTERP_DETAIL   (REF_NO, INC_TYPE_CODE, FEEDER_CODE, VOL_LEVEL, START_DT_TIME,     GRID_CODE, END_DT_TIME, LOAD_AMP)
Values   (2116, 'UN', 'RUSG2L5', '33', TO_DATE('09/10/2008 00:26:00', 'MM/DD/YYYY HH24:MI:SS'),     'RUS', TO_DATE('09/10/2008 00:55:00', 'MM/DD/YYYY HH24:MI:SS'), 160);
Insert into INTERP_DETAIL   (REF_NO, INC_TYPE_CODE, FEEDER_CODE, VOL_LEVEL, START_DT_TIME,     GRID_CODE, END_DT_TIME, LOAD_AMP)
Values   (2116, 'UN', 'RUSG10L5', '33', TO_DATE('09/10/2008 00:27:00', 'MM/DD/YYYY HH24:MI:SS'),     'RUS', TO_DATE('09/10/2008 00:55:00', 'MM/DD/YYYY HH24:MI:SS'), 84);
Insert into INTERP_DETAIL   (REF_NO, INC_TYPE_CODE, FEEDER_CODE, VOL_LEVEL, START_DT_TIME,     GRID_CODE, END_DT_TIME, LOAD_AMP)
Values   (2116, 'UN', 'RUSG29L5', '11', TO_DATE('09/09/2008 23:43:00', 'MM/DD/YYYY HH24:MI:SS'),     'RUS', TO_DATE('09/10/2008 01:04:00', 'MM/DD/YYYY HH24:MI:SS'), 26);
Insert into INTERP_DETAIL   (REF_NO, INC_TYPE_CODE, FEEDER_CODE, VOL_LEVEL, START_DT_TIME,     GRID_CODE, END_DT_TIME, LOAD_AMP)
Values   (2116, 'UN', 'RUSG30L5', '11', TO_DATE('09/09/2008 23:43:00', 'MM/DD/YYYY HH24:MI:SS'),     'RUS', TO_DATE('09/10/2008 01:04:00', 'MM/DD/YYYY HH24:MI:SS'), 120);Query to fetch data is
select round (case id.VOL_LEVEL --CALCULATING LOAD IN INTERUPPTION DETAIL DIVIDED ACCORDING TO TIME SLICES
                when '33' then
                      (id.LOAD_AMP/20)
                when '11' then
                      (id.LOAD_AMP/60)
               end * 1000 / E.LOAD_KW
             ) AS Effected_Customers
    , (  to_date(to_char( id.END_DT_TIME,'dd/mm/rrrr')||least(e.TO_TIME,to_char( id.END_DT_TIME,'hh24:mi')), 'dd/mm/rrrr hh24:mi')
       - to_date(to_char(id.START_DT_TIME, 'dd/mm/rrrr')||greatest(e.FROM_TIME, to_char(id.START_DT_TIME,'hh24:mi')), 'dd/mm/rrrr hh24:mi') ) * 24 * 60 as duration
    , e.load_kw as estimated_Load_Per_Customer
    , to_date(to_char(id.START_DT_TIME, 'dd/mm/rrrr')||greatest(e.FROM_TIME, to_char(id.START_DT_TIME,'hh24:mi')), 'dd/mm/rrrr hh24:mi') as  intstartTime
    , to_date(to_char( id.END_DT_TIME,'dd/mm/rrrr')||least(e.TO_TIME,to_char( id.END_DT_TIME,'hh24:mi')), 'dd/mm/rrrr hh24:mi') as  intendTime
    , i.INC_TYPE_CODE, i.REF_NO, e.TO_TIME, id.FEEDER_CODE
from  est_load e, interp_detail id, incident i, region_district rd
where e.DISTRICT_CODE = i.DISTRICT_CODE
and   i.REF_NO = id.REF_NO
and   i.INC_TYPE_CODE = id.INC_TYPE_CODE
and   i.DISTRICT_CODE = rd.DISTRICT_CODE
and   to_date(to_char(id.START_DT_TIME,'rrrrmm'),'rrrrmm') >= to_date(to_char(id.END_DT_TIME,'rrrr') || lpad(e.FROM_MONTH,2,'0'),'rrrrmm')  
and   to_date(to_char(id.END_DT_TIME,'rrrrmm'),'rrrrmm')   <= to_date(to_char(id.START_DT_TIME,'rrrr') || lpad(e.TO_MONTH,2,'0'),'rrrrmm')
and   to_char(id.START_DT_TIME,'hh24:mi') <  e.TO_TIME
and   to_char(id.END_DT_TIME,'hh24:mi')   >  e.FROM_TIME
and   i.INC_TYPE_CODE = 'UN' and i.REF_NO = 2116 but the problem here is query returns only 2 rows it supposed to return more then 16 rows, will you plz take a look.
Thanks and regards, Khawar
Edited by: S. Khawar on Apr 5, 2009 10:03 AM
Edited by: S. Khawar on Apr 5, 2009 8:11 PM

Similar Messages

  • Slicer Time Dimension Issue with Cube Functions

    Hi,
    Hoping someone can help me figure out right approach here.
    Summary:
    Using Excel 2013 connected to a SSAS cube as data source, and cube functions with slicers to create a dashboard.
    Have following time dimension slicers; Fiscal Year, Fiscal Quarter, Fiscal Month, Fiscal Week & Date, that are used to slice data based on user selection, along
    with a sales measure.
    Below is example of Slicer name and CubeMember function for each:
    Slicer_Fiscal_Year: 
    =CUBEMEMBER("Cube","[Date].[Fiscal Year].&[2015]")
    Slicer_Fiscal_Quarter: 
    =CUBEMEMBER("Cube","[Date].[Fiscal Quarter].[All]")
    Slicer_Fiscal_Month: 
    =CUBEMEMBER("Cube","[Date].[Fiscal Month].&[201408]")
    Slicer_Fiscal_Week: 
    =CUBEMEMBER("Cube","[Date].[Fiscal Week].&[201509]")
    Slicer_Date: 
    =CUBEMEMBER("Cube","[Date].[Date].[All]")
    Problem:
    What I am trying to do is to build a table with cube functions that takes the lowest grain of the slicer time dimension selected, shows the current member, plus
    the prior 7 so I can have an 8 period trending view table that I will build a chart from. In the above example that would mean that it would look at Slicer_Fiscal_Week since that is lowest grain that has an attribute other than All, and then show me the prior
    7 periods. In this case 201509 means Week 9, so I would want to show in table Week 9 back to Week 2. But if Slicer_Fiscal_Week was set to All, along with Slicer_Date, then Fiscal Month would be lowest grain, so I would want to show Fiscal Months from August
    (201408) back to January 2014. I know how to use CubeRankedMember to pull the value from what is selected in the slicer, the problem is figuring out how to pass the lowest grain time dimension so that I can use lag or some other MDX function to get the previous
    periods.
    Any help on this would be greatly appreciated.
    <object height="1" id="plugin0" style=";z-index:1000;" type="application/x-dgnria" width="1"><param name="tabId" value="{28593A5C-70C0-4593-9764-80C76B51795C}"
    /></object>

    Hello,
    Thank you for your question.
    I am trying to involve someone familiar with this topic to further look at this issue.
    George Zhao
    TechNet Community Support
    It's recommended to download and install
    Configuration Analyzer Tool (OffCAT), which is developed by Microsoft Support teams. Once the tool is installed, you can run it at any time to scan for hundreds of known issues in Office
    programs.

  • How to convert date-time according to the Time Zone the client

    Urgent! Help wanted!
    I extract a date-time field (which is GMT time) from the central database but I need to convert it accordding to the TimeZone of the user and also the so-called winter time and summer time in the local. Any one has any good solution?
    Thanks.

    Use a Calendar, Timezone and Locale objects like this,
    TimeZone tz = TimeZone.getTimeZone("Germany/Berlin");
    Calendar cal = Calendar.getInstance(tz, Locale.GERMAN);
    long date = 0; // assign your central database value to this variable
    cal.setTime(new Date(date));
    Now you can use the Calendar object 'cal' to retrieve the time according to the set locale and timezone.
    These objects provide tonnes of features for finding out timezones and day light savings times. So check out the APIs as well.
    I hope this helps you out.

  • Block Purchaisng screen for one time vendor acount group

    Hi Experts,
    Hope everyone is doing good.
    How can we block purchasing screen for one time Vendor account group.
    User requirement:
    He wanted to maintain only Accounting data for one time vendor but not purchasing data.Though I have suppressed all the Purchasing related fields in Screen layout for Vendor account group but still at the time of creation of one time vendor "create Vendor:purchasing screen is coming"
    Is there any option to suppress/Skip  this screen "Create Vendor:Purchasing Data" ?
    Regards,
    Uzair

    - Account group is just one of the four factors influencing the field status. (If all the fields are suppressed in a screen the screen will not appear during the creation of the VMR).
    - Company Code, Transaction Used and Purchasing Organization are otehr influencing factors.
    - Since the field status depend on several influencing factors, Link rules are necessary which determine the instance of the field status if different influencing factors have different effects.
    - Hide has priority 1, Display 2, Mandatory 3, Optional entry 4
    - Say for e.g. you want a field to be suppresses due to account group but a mandatory entry due to purchasing organization. Instance hide has the highest priority. If a field was suppresses by account group what was specified by purchasing organization becomes irrelevant.
    - Display overrides Required & Optional Entry
    - Required entry overrides Optional entry

  • Block One-time Vendor Account Group

    Hello,
    I would like to block an One-time Vendor Account, but at the transaccion OMSG there is just the option to eliminate.
    Deleting the account group is the only choice or there is another way to make it?
    If I delete a one-time vendor account group, I would like to know what are the risks and advices to tell may customer.
    thanks,
    Kathia Tsuboi

    Hello,
    There is no blocking of option to one time vendor. It is used for a single time and no further use of this one time vendor account. When you create one time vendor, just an vendor account number gets created and when prepare transaction data like invoice, the one time vendor address gets filled in.
    I would NOT recommend to delete the one time vendor account group, they may result in invalidate your master data. Therefore, not to delete the vendor account group, but you should create alternative one time vendor account group, if the requirement insists.
    Regards,
    Ravi

  • IQ03 - one time customer account group not shown in ship-to party field

    Hi,
    Anyone can help out this?
    In IQ03, for one time customer account, ship-to party field not updated. For others account group is updated.
    Is this SAP standard setting that not shown the ship-to/sold-to details in IQ03 for one time customer account?
    Thanks in advance.

    Update some details:
    1. Our one-time customer account group setting is customized from standard one time customer account.
    2. Partner determination done same as sold-to party.
    I came accross this "One time customer do not have partner functions tab (no SP, BP, PY, SH) active.... " in Thread: One time customer Posted by Bageerath Chery.
    Can anyone explain further on this?
    As if this is standard, meaning can explain why one-time customer not shown in ship-to field although the setting at equipment > Assign Partner Determination Procedure to Equipment Category done.
    Or any else setting to check? Pls advise..

  • I just bought a subscription to adobe reader so I could convert by book pdf to word. I download it per your instructions, but when I open it as docx, it is all code. I've done this 3 times according to the instructions.

    I just bought a subscription to adobe reader so I could convert by book pdf to word. I download it per your instructions, but when I open it as docx, it is all code. I've done this 3 times according to the instructions.

    The iPhone and iPad draw whatever charging current they require. The iPad draws more.

  • How to get po item condition type according schema group

    hi experts,
    i want to get po item condition type according schema group.
    for example, in xk03, if the "schema group, vendor"in purchasing data view is set to 'Z3', in the purchase order which is made for this vendor, the po item's gross price condition type is hwxx.
    if the "schema group, vendor" is set to 'Z2', the po item's gross price condition type is pbxx.
    my question is : how to get po item condition type according schema group?
    hunger for ur advice and thanks a lot!

    several steps you need to go
    1. you need to get the purcahsing group schema against your purchasing group from table T024E.
    2. get the vendor group schema from vendor master data table LFxxxxxx
    3. get the pricing schema from table TMKS via the selection criteria purchasing group schema and vendor group schema
    4. go to the table T683S via inputing Usage, application and pricing determination procedure.
    5. now you got it.

  • Adjust delivery time according to cycle  (every 2 weeks delivery).

    We want to setup cycle planning in MPR area on which the requirements will come when stock falls below the reorderpoint.
    By cycle planning we expect that system will adjust delivery time according to cycle  (every 2 weeks delivery).
    Please note that for this MRP area we are using manual ROP (no forecast is calculated)
    thx

    Hi VAIBHAV,
    Normally you can't tell MRP to wait with the delivery until the next ordinary delivery of the vendor if you use re-order point planning, because you might end up in stock out situation.
    However, SAP provides some tools to combine time-phased planning with reorder point planning. Please check the business case described at [http://help.sap.com/erp2005_ehp_02/helpdata/en/7d/c2821c454011d182b40000e829fbfe/frameset.htm] and there select MRP procedures... -> Time-Phased Planning -> Time-phased Planning Process with Reorder Point Planning.
    In this case you shall also maintain the two-weeks cycle in the field "planning calendar" on MRP 2 view of the material master.
    Is this what you mean?
    BR
    Raf

  • After restoring contacts from time machine, all groups are empty

    I had to restore a backup of my address book folder from time machine. Library/Application Support/Address Book, I also removed deleted the com.apple.addressbook.plist files.  When I open address book, all the contacts and group names show, but the groups are now empty when I click on them.  Any thoughts?

    Quit Contacts or Address Book if it’s running. If you use iCloud, uncheck the box marked Contacts in the iCloud preference pane.
    Triple-click the text on the line below to select it, then copy it to the Clipboard (command-C):
    ~/Library/Application Support/AddressBook/Metadata
    In the Finder, select
    Go ▹ Go to Folder
    from the menu bar, paste into the box that opens (command-V), and press return.
    A Finder window will open with a folder selected. Move the selected folder to the Desktop, leaving the window open for now.
    Relaunch the application and test. If there’s no improvement, quit and put back the item you moved, overwriting the newer one that may have been created in its place. Otherwise, delete the item.

  • How to avoid crosstab - Show number of days according to groups

    Morning all,
    I think you all would agree with me that even having crosstab as a great tool in Crystal 2008, there are still quite allot of limitations to it.
    I have created a report using crosstab which shows number of days and jobs according to those days grouped by account number, product code, sales area. This report is working fine until my director asked me to further group those days according to sub categories of lenses.
    For example
    Crosstab shows
    Number of days - Day 1,day 2, day 3
    Number of jobs - 111----123--1213
    Percentage - -
    12%---34% 60%
    Now if you look at the example it says day 1, 111 jobs went out. What the director would like to see is those jobs being sub divided into types of lenses.
    So out of 111 jobs, 25 would be Finished lenses, 30 could be uncut lenses and so on.
    The new report should be like this
    Number of days -
    Day1---Day2---Day3
    Number of Jobs:-
    Finished -
    25--34-----23
    Uncut--3045-----23
    AR--7056-----76
    Total----125135----122
    Percentage:-
    Finished -
    25%--34%-----23%
    Uncut--30%45%-----23%
    AR--70%56%-----76%
    Total----100%100%----100%
    Now if we look at the above criteria it seems that I have to use groups even further down the report where I am using crosstab at the moment. This means I have to get rid of the crosstab and run a report manually.
    However the big question is, how to get the report calculating number of days and jobs according to customer account number, product code and sales area manually?
    I tried the following formula but this requires to write way too many formulas, for example some of the jobs have taken more than 60 days and if i use this formula I have to write 60 formulas for number of days which is not feasable.
    **//provided by IIbas in another forum**
    whileprintingrecords;
    numbervar day0;
    numbervar day1;
    numbervar day2;
    if {@workingdays} = 0 then
    day0 := day0 + 1 else
    if {@workingdays} = 1 then
    day1 := day1 + 1 else
    if {@workingdays} = 2 then
    day2 := day2 + 1 else //up to the maximum number of days.
    Then in the report footer, reference the days in separate formulas, and identify them with text boxes, e.g.,
    //{@day0};
    whileprintingrecords;
    numbervar day0;
    I can sort out the Finished, uncut,AR by grouping them however I am wondering how to create a manual running total of jobs complying with number of days without using crosstab.
    Any ideas?
    Many thanks
    Regards
    Jehanzeb

    no answer closing

  • Delete email lists more than just one at a time. In groups or blocks.

    I want to delete a lot of old emails. Instead of doing it one at a time can I do a group all at one time?

    Yes, you can.

  • Servers take an endless time at applying group policy settings

    We have some Windows 2008R2 RDS servers that have been given a syspreped image. After a few day in production, and several nightly reboots, the servers start to hang at applying group policy setting. I have created a gpsvc.log file. What can be wrong with
    these servers?
    When i reboot the server without network connection, the reboot time is fine. The user login still takes forever.
    GPSVC(fc.4ec) 08:38:21:227 MachinePolicyCallback: Setting status UI to Beleid Group Policy Services toepassen...
    GPSVC(fc.4ec) 08:38:21:227 ProcessGPOList: No changes. CSE will not be passed in the IwbemServices intf ptr
    GPSVC(fc.1a4) 08:38:21:227 Message Status = <Beleid Group Policy Services toepassen...>
    GPSVC(fc.1a4) 08:38:21:227 Setting GPsession state = 1
    GPSVC(fc.5b4) 08:38:21:820 ProcessGroupPolicyCompletedExInternal: Entering. Extension = {827D319E-6EAC-11D2-A4EA-00C04F79F83A}, dwStatus = 0x0
    GPSVC(fc.5b4) 08:38:21:867 GetWbemServices: CoCreateInstance succeeded
    GPSVC(fc.4ec) 08:38:22:475 ProcessGroupPolicyCompletedExInternal: Entering. Extension = {91FBB303-0CD5-4055-BF42-E512A681B325}, dwStatus = 0x0
    GPSVC(fc.4ec) 08:38:22:491 GetWbemServices: CoCreateInstance succeeded
    GPSVC(5dc.5e0) 08:38:24:285 CGPNotify::RegisterForNotification: Entering with target Machine and event 0x2a0
    GPSVC(5dc.5e0) 08:38:24:285 Client_InitialRegisterForNotification: User = machine, changenumber = 0
    GPSVC(fc.1b0) 08:38:24:285 Target = Machine
    GPSVC(5dc.5e0) 08:38:24:285 Client_RegisterForNotification: User = machine, changenumber = 0
    GPSVC(5dc.5e0) 08:38:24:285 CGPNotify::RegisterForNotification: Exiting with status = 0
    GPSVC(fc.1b0) 08:38:24:285 Target = Machine, ChangeNumber 0
    GPSVC(5dc.5e0) 08:38:24:285 CGPNotify::RegisterForNotification: Entering with target S-1-5-18 and event 0x3d4
    GPSVC(5dc.5e0) 08:38:24:285 Client_InitialRegisterForNotification: User = S-1-5-18, changenumber = 0
    GPSVC(fc.1b0) 08:38:24:285 Target = S-1-5-18
    GPSVC(fc.1b0) 08:38:24:285 Could not find user by sid, finding user by session id
    GPSVC(fc.1b0) 08:38:24:285 Caller requesting for user notification/lock is from session 0
    GPSVC(5dc.5e0) 08:38:24:285 Client_RegisterForNotification: User = S-1-5-18, changenumber = 0
    GPSVC(5dc.5e0) 08:38:24:285 CGPNotify::RegisterForNotification: Exiting with status = 0
    GPSVC(fc.1b0) 08:38:24:285 Could not find user by sid, finding user by session id
    GPSVC(fc.1b0) 08:38:24:285 Caller requesting for user notification/lock is from session 0
    GPSVC(62c.64c) 08:38:25:330 CGPNotify::RegisterForNotification: Entering with target Machine and event 0x1d4
    GPSVC(62c.64c) 08:38:25:330 Client_InitialRegisterForNotification: User = machine, changenumber = 0
    GPSVC(fc.1b0) 08:38:25:330 Target = Machine
    GPSVC(62c.64c) 08:38:25:330 Client_RegisterForNotification: User = machine, changenumber = 0
    GPSVC(62c.64c) 08:38:25:330 CGPNotify::RegisterForNotification: Exiting with status = 0
    GPSVC(298.2c0) 08:38:28:310 CGPNotify::RegisterForNotification: Entering with target Machine and event 0xab0
    GPSVC(298.2c0) 08:38:28:310 Client_InitialRegisterForNotification: User = machine, changenumber = 0
    GPSVC(fc.1b0) 08:38:28:310 Target = Machine
    GPSVC(298.2c0) 08:38:28:310 Client_RegisterForNotification: User = machine, changenumber = 0
    GPSVC(298.2c0) 08:38:28:310 CGPNotify::RegisterForNotification: Exiting with status = 0
    GPSVC(fc.1b0) 08:38:28:310 Target = Machine, ChangeNumber 0
    GPSVC(fc.7c0) 08:38:39:401 CGPNotify::RegisterForNotification: Entering with target Machine and event 0x93c
    GPSVC(fc.7c0) 08:38:39:401 Client_InitialRegisterForNotification: User = machine, changenumber = 0
    GPSVC(fc.95c) 08:38:39:401 Target = Machine
    GPSVC(fc.7c0) 08:38:39:401 Client_RegisterForNotification: User = machine, changenumber = 0
    GPSVC(fc.7c0) 08:38:39:401 CGPNotify::RegisterForNotification: Exiting with status = 0
    GPSVC(fc.95c) 08:38:39:401 Target = Machine, ChangeNumber 0
    GPSVC(53c.580) 08:40:20:755 CGPNotify::RegisterForNotification: Entering with target Machine and event 0x608
    GPSVC(53c.580) 08:40:20:755 Client_InitialRegisterForNotification: User = machine, changenumber = 0
    GPSVC(fc.1c4) 08:40:20:755 Target = Machine
    GPSVC(53c.580) 08:40:20:755 Client_RegisterForNotification: User = machine, changenumber = 0
    GPSVC(53c.580) 08:40:20:755 CGPNotify::RegisterForNotification: Exiting with status = 0
    GPSVC(53c.580) 08:40:21:098 CGPNotify::RegisterForNotification: Entering with target Machine and event 0x64c
    GPSVC(53c.580) 08:40:21:098 Client_InitialRegisterForNotification: User = machine, changenumber = 0
    GPSVC(fc.1c4) 08:40:21:113 Target = Machine
    GPSVC(53c.580) 08:40:21:113 Client_RegisterForNotification: User = machine, changenumber = 0
    GPSVC(53c.580) 08:40:21:113 CGPNotify::RegisterForNotification: Exiting with status = 0
    GPSVC(53c.564) 08:40:21:238 CGPNotify::RegisterForNotification: Entering with target Machine and event 0x67c
    GPSVC(53c.564) 08:40:21:238 Client_InitialRegisterForNotification: User = machine, changenumber = 0
    GPSVC(fc.1c4) 08:40:21:238 Target = Machine
    GPSVC(53c.564) 08:40:21:238 Client_RegisterForNotification: User = machine, changenumber = 0
    GPSVC(53c.564) 08:40:21:238 CGPNotify::RegisterForNotification: Exiting with status = 0
    GPSVC(200.f6c) 08:41:11:501 CGPNotify::RegisterForNotification: Entering with target Machine and event 0x350
    GPSVC(200.f6c) 08:41:11:501 Client_InitialRegisterForNotification: User = machine, changenumber = 0
    GPSVC(fc.1c4) 08:41:11:501 Target = Machine
    GPSVC(200.f6c) 08:41:11:501 Client_RegisterForNotification: User = machine, changenumber = 0
    GPSVC(200.f6c) 08:41:11:501 CGPNotify::RegisterForNotification: Exiting with status = 0
    GPSVC(fc.1c4) 08:41:11:891 Target = Machine
    GPSVC(fc.1c4) 08:41:11:891 Target = Machine, ChangeNumber 0
    GPSVC(fc.7d0) 08:41:11:985 Target = Machine
    GPSVC(fc.7d0) 08:41:11:985 Target = Machine, ChangeNumber 0
    GPSVC(fc.7d0) 08:41:11:985 Sid = (null), dwTimeout = 600000, dwFlags = 268435456
    GPSVC(fc.7d0) 08:41:11:985 LockPolicySection called for user <Machine>
    GPSVC(fc.7d0) 08:41:11:985 Async Lock called
    GPSVC(fc.7d0) 08:41:11:985 Reader has to wait for lock. ReaderID : 1.
    GPSVC(fc.7d0) 08:41:11:985 Registering wait for lock notification
    GPSVC(fc.9d8) 08:41:13:015 CGPNotify::RegisterForNotification: Entering with target Machine and event 0xcbc
    GPSVC(fc.9d8) 08:41:13:015 Client_InitialRegisterForNotification: User = machine, changenumber = 0
    GPSVC(fc.7d0) 08:41:13:015 Target = Machine
    GPSVC(fc.9d8) 08:41:13:015 Client_RegisterForNotification: User = machine, changenumber = 0
    GPSVC(fc.9d8) 08:41:13:015 CGPNotify::RegisterForNotification: Exiting with status = 0
    GPSVC(fc.9d8) 08:41:13:015 CGPNotify::RegisterForNotification: Entering with target Machine and event 0xd24
    GPSVC(fc.9d8) 08:41:13:015 Client_InitialRegisterForNotification: User = machine, changenumber = 0
    GPSVC(fc.7d0) 08:41:13:015 Target = Machine
    GPSVC(fc.9d8) 08:41:13:015 Client_RegisterForNotification: User = machine, changenumber = 0
    GPSVC(fc.9d8) 08:41:13:015 CGPNotify::RegisterForNotification: Exiting with status = 0
    GPSVC(200.1060) 08:43:10:223 CGPNotify::UnregisterNotification: Entering with event 0x350
    GPSVC(200.1060) 08:43:10:223 CGPNotify::AbortAsyncRegistration: No asyn registration is pending
    GPSVC(200.1060) 08:43:10:223 CGPNotify::UnregisterNotification: Canceling pending calls
    GPSVC(200.1060) 08:43:10:223 Client_CompleteNotificationCall: failed with 0x71a
    GPSVC(200.1060) 08:43:10:223 CGPNotify::UnregisterNotification: Cancelled pending calls
    GPSVC(200.1060) 08:43:10:223 CGPNotify::UnregisterNotification: Exiting with dwStatus = 0x0
    GPSVC(fc.1054) 08:43:16:252 Target = Machine
    GPSVC(fc.1054) 08:43:16:252 Target = Machine, ChangeNumber 0
    GPSVC(fc.1138) 08:43:24:188 CGPNotify::RegisterForNotification: Entering with target Machine and event 0xeac
    GPSVC(fc.1138) 08:43:24:188 Client_InitialRegisterForNotification: User = machine, changenumber = 0
    GPSVC(fc.7d0) 08:43:24:188 Target = Machine
    GPSVC(fc.1138) 08:43:24:188 Client_RegisterForNotification: User = machine, changenumber = 0
    GPSVC(fc.1138) 08:43:24:188 CGPNotify::RegisterForNotification: Exiting with status = 0
    GPSVC(fc.1054) 08:43:29:418 Target = Machine
    GPSVC(fc.1054) 08:43:29:418 Target = Machine, ChangeNumber 0
    GPSVC(fc.1054) 08:43:50:304 Target = Machine
    GPSVC(fc.1054) 08:43:50:304 Target = Machine, ChangeNumber 0
    GPSVC(fc.1374) 08:51:06:327 Found the Waiting Rpc Reader in the waiting list. Removing it...
    GPSVC(fc.1374) 08:51:06:327 Lock timeout
    Gert MCITP SA, EA & VA

    Hi,
    From the log you submit, I found the following error:
    GPSVC(f0.13fc) 03:00:18:665 Client_CompleteNotificationCall: failed with 0x525
    GPSVC(2f0.baf4) 03:00:18:665 CGPNotify::OnNotificationTriggered: Completenotification failed with 1317
    GPSVC(518.e980) 03:00:18:665 Client_CompleteNotificationCall: failed with 0x6ba
    GPSVC(f0.13fc) 03:00:18:665 CGPNotify::OnNotificationTriggered: Trying to recover from error 1722
    GPSVC(518.e980) 03:00:18:665 CGPNotify::RegisterNotificationAsynchronously: Starting async registration
    GPSVC(3b8.3e0) 03:04:19:034 Client_RegisterForNotification: CheckRegisterForNotification returned error 0x6d9
    GPSVC(3b8.3e0) 03:04:19:034 CGPNotify::RegisterForNotification: Service not RUNNING. waiting
    GPSVC(3b8.3e0) 03:04:19:034 CGPNotify::RegisterForNotification: Trying to recover from error 1753
    GPSVC(3b8.3e0) 03:04:19:034 CGPNotify::RegisterNotificationAsynchronously: Starting async registration
    GPSVC(100.4c8) 03:05:07:753 ProcessGPOs: OpenThreadToken failed with error 1008, assuming thread is not impersonating
    GPSVC(100.13f4) 07:54:09:864 GetOldSidString:  Failed to open profile profile guid key with error 2
    GPSVC(658.2354) 09:52:41:726 Client_ProcessRefresh: ProcessRefresh returned error 0x5b4
    GPSVC(658.2354) 09:52:41:726 GetGPOList: Client_ProcessRefresh failed with 0x5b4.
    GPSVC(658.2354) 09:52:41:726 Exiting RefreshPolicyForPrincipal with status = 1460
    GPSVC(100.1a7c) 10:48:26:711 CGPAdminEventInitFailure::Initialize(): FormatMessage failed to look up error code (0x4005) due to error 317. Can not log error description.
    GPSVC(100.219c) 10:48:26:711 ProcessGPOList: Extension Internet Explorer Branding was not able to log data. Error = 0x80004005, dwRet = 1252,leaving the log dirty
    GPSVC(100.19b4) 10:48:27:491 ProcessGPOList: Extension Internet Explorer Branding was not able to log data. Error = 0x80004005, dwRet = 1252,leaving the log dirty
    1. Please try to renamed the files on the folder  c:\windows\system32\GroupPolicy to .old and ran Gpupdate /force. 
    2. Please verify the DNS set correctly and DNS Client Service is enabled. Restart the DNS Client Service.
    Hope this helps!
    Best Regards
    Elytis Cheng
    TechNetSubscriber
    Support
    If
    you are TechNetSubscription user
    and have any feedback on our support quality, please send your feedback here.
    Elytis Cheng
    TechNet Community Support

  • OID First Time Full Reconciliation - group/role reconciliation question

    My client has some roles/groups created in OID. The initial set of users lies over there. I have to bring the initial load of users into OIM. The existing set of users is around 5000. But some users belong to different groups/roles. Now if I want to do a first time reconciliation to bring all these initial set of user profiles and accounts into OIM; where do I need to specify the groups/roles in OID resource object?
    I went through the OID connector guide. But in there, in the section "3.1 Performing First-Time Reconciliation", it doesn't mention anywhere to create any multivalued attribute/child form or anything. What are the steps that are needed to be taken? If I just reconcile the group/role lookup values, will it populate those values within the user process form? If so, which fields will co-relate with that?
    Thanks,
    - oidm.

    Thanks Raj. But I think I am a bit lost over here.
    So you mean to say I don't need to run the scheduled tasks which are related to populating the groups/roles lookups for first time full reconciliation? And also you mean to say that we only need these lookups at the time of provisioning user profiles to target system?
    I have to create identities within OIM from OID so I have to run the 'OID User Trusted Recon Task' and not 'OID User Target Recon Task'.
    Basically, my question is how will the roles/groups be depicted in the user account when I will do a trusted source reconciliation? If so, which fields in process form will hold those values? Do I need to run the lookup reconciliation tasks for the same or not?
    Thanks,
    - oidm.

  • Process times in recipe group

    Hi,
    How to  specify different process times in for same operation in a recipe group based on the material.

    Veesh,
    This is applicable for all task list type like, like Routing, Rate Routing, Master Recipe, Referance Routing Inspection Plan, Maintenance Plan etc...
    Regards,
    Prasobh

Maybe you are looking for

  • Get multiple values from Command-Line

    Can any body tell how can I do this� When I input a number, then I should be able to insert that number of lines (rows). Note that number of columns is always 4. I.e.: If I put number 3 in command-line, It should be like this & then exit from the pro

  • Trying to reinstall CS5, but I've lost the Serial Number from Flash Professional 8, and it's no longer shown on my account page.

    Something like 10 years ago (2004ish), I bought Flash Professional 8, and I upgraded to CS5 back in 2011. Following a number of hardware upgrades, including a new hard drive, I need both serial numbers to reinstall; I've done so several times in the

  • Getting an XML string into BI

    Hi, I am loading data through flat files and have a field in te flat file which is an XML string. It is esentially a combination of characterisitic value embedded in one string. What should i do to pick specific values from the string and put it into

  • Cancel Invoice Document MR8M-

    Hi Gurus, Good day! When I try to reverse the document # I'm getting an error message of Invoice document number cannot be processed further. Please help me regarding with this problem. Regards, Virgilio Message was edited by:         Virgilio Padios

  • TS3276 Mail seems to be frozen.  What can I do?

    My Mail was working fine and then one day when I turned on my Air, Mail was not working and I can't get it back.  I can see my old emails but it won't get any new ones, or let me send anything.  It seems to be frozen.  When I look at connection docto