Restrict the detail record based on the record indicator

Hi, i have a master detail form
when i query the form at header block it shows all the headers say
header block
header, line num, desc
1, 1, pen
1 ,2, rubber
1 ,3, sketchpen
line block
line num, sub item ,cost
1 ,1.1, 50
1 ,1.2, 60
2 ,2.1, 70
2, 2.2, 5
it shows the output in this way
i want to restrict the line level block (say if my cursor is at record indicating row 1 in header) then in line level it should show
lines pertaining to line num 1 and header 1 --eg pen records
if my cursor is at line num 2 in header block, in line level block it should show only line num 2 details ie rubber details, how can i restrict this.
Thanks,

Define the relation between header and detail
join condition : header.line_num = detail.line_num
delete record behaviour : non-isolated
prevent masterless operations : Yes
after this if you navigate, the detail records will automatically gets queried accordingly.
Regards
Dora

Similar Messages

  • How to create a record based on the name of a file in the file-system?

    Hi,
    With a lot of pictures I want to have a database to gather some information about these pictures.
    First question is how to generate a record based on a file in the file system?
    e.g. the pictures are "c:\fotos\2009\01\disc_001.jpg" to "c:\foto\2009\01\dis_98.jpg" .
    now i want to create records with as one of the attributes the name of the picture (not the picture itself). how to create these records (based on the information of the file-ssytem). i.e. the number of records should be the same as the number of pictures.
    any suggestions?
    any reaction will be appreciated.
    Leo

    Link to Create directory
    http://www.adp-gmbh.ch/ora/sql/create_directory.html
    You can create a list of files in the directory and read the list files from that directory.
    [UTL_FILE Documentation |http://download.oracle.com/docs/cd/B14117_01/appdev.101/b10802/u_file.htm#996728]
    [Solution using Java|http://asktom.oracle.com/pls/asktom/f?p=100:11:0::::P11_QUESTION_ID:439619916584]
    SS

  • Retrive Records based on the content in a Clob Feild

    Retrive Records based on the content in a Clob Feild
    I have a Table NoteFile which contains a Clob Feild NoteFileContent
    and is refrenced by PK DocID
    i need to Match DocID with other Tables Document and folderdocument
    My Query is as Below
    SELECT Doc.Pap_Doc_ID, Doc.Pap_Doc_Name , NF.NoteFileContent
    From NoteFile NF , Document Doc, folderdocument FD
    Where Doc.Pap_Doc_ID = FD.FoldDoc_ID and FD.FoldDoc_ParentID <> 3 and
    NF.DocID = DOC.Pap_Doc_ID And NF.NoteFileContent Like '%a%'
    The above query throws
    ORA-00600: internal error code, arguments: [504], [0x7ADEBE00], [2], [1],
    [cache buffers chains], [723], [0], [0x7ADEBE00]

    Hi,
    We can resize it.Always give the height and weight in
    percentage format. and turn off the horizontal n vertical scroll
    policy in u r main application.
    Hopes it helps you...

  • Select records based on the closest given time

    Dear SQL gurus,
    I have a table T1:
    Name Null? Type
    ID NOT NULL NUMBER(5)
    MOMENT NOT NULL DATE [DD.MM.YYYY HH24:MI]
    MEASUREMENT NOT NULL NUMBER(8,3)
    Example (ID, MOMENT, MEASUREMENT)
    -- START OF EXAMPLE --
    9380 18.11.2000 03:45 17.6
    9380 18.11.2000 04:30 17.3
    9380 18.11.2000 05:45 16.8
    9380 18.11.2000 06:15 16.8
    9380 18.11.2000 07:00 16.2
    9380 18.11.2000 07:30 16.2
    9380 18.11.2000 08:15 16
    9380 18.11.2000 08:45 15.7
    9380 18.11.2000 09:30 15.4
    9380 18.11.2000 10:00 15.4
    9380 18.11.2000 11:15 15.4
    9380 18.11.2000 11:45 15.4
    9380 18.11.2000 12:30 15.4
    9380 18.11.2000 13:00 15.4
    9380 18.11.2000 13:45 15.4
    --- END OF EXAMPLE --
    How to select records based on the:
    - time period specified by the day only [DD.MM.YYYY] - CONDITION 1
    - with values for 6AM only, and if not available, with values closest to 6AM - CONDITION 2
    (if the time gap in MOMENT field is too big, lets say > 5h then choose the average between the value before 6AM (ex. 4:15AM) and the value after the 6AM (ex. 9:45AM))
    CONDITION 1 (something like): moment between '01.01.2005' and '31.12.2004' - this is OK
    CONDITION 2: I do not know how to formulate, especially if 6AM value is not availabe, and I have to find the closest available value, or get the avergae from the two adjacent values.
    Maybe cursor magic??? Thanks a lot for your help.
    Rado

    About condition two, would the following select be of use to you? Picking the first record could be achived by rownum, analytic function, etc.
    WITH t1 AS (SELECT 9380 id, TO_DATE('18.11.2000 03:45', 'dd.mm.yyyy hh24:mi') moment,  17.6 measurement
                  FROM dual
                 UNION 
                SELECT 9380 id, TO_DATE('18.11.2000 04:30', 'dd.mm.yyyy hh24:mi') moment,  17.3 measurement
                  FROM dual
                 UNION
                SELECT 9380 id, TO_DATE('18.11.2000 05:45', 'dd.mm.yyyy hh24:mi') moment,  16.8 measurement
                  FROM dual
                 UNION
                SELECT 9380 id, TO_DATE('18.11.2000 06:15', 'dd.mm.yyyy hh24:mi') moment,  16.8 measurement
                  FROM dual
    SELECT id, moment, measurement, diff
      FROM (SELECT id, moment, measurement,
                   moment - TO_DATE(TO_CHAR(moment, 'dd.mm.yyyy ') || '06:00', 'dd.mm.yyyy hh24:mi') diff
              FROM t1
    ORDER BY abs(diff) asc, SIGN(diff) desc;
      C.

  • SQL Query to retrieve the All records based on the Max Dates.

    Hello all,
    I am trying to retrieve the newest record based on the date field (  nextDate  ).
    Currently there are only 4 records in the MC_Maintenance table and two in the Machine table.
    Machine table
    MC_id             EquipID          
    1                      0227
    MC_id             EquipID
    2                     0228
    MC_Maintenance table
    Maint_id           MC_id             Next_maint                  
    1                      2                      08/25/2010     
    2                      2                      07/01/2010
    3                      1                      06/11/2010
    4                      1                      07/11/2010
    What I  am trying to accomplish is,
    list the two machines from the Machine table with the MAX(Next_maint) controlling the MC_Maintenance output list
    These are the records that I would like to Display.
    Maint_id           MC_id             Next_maint                  
    1                      2                      08/25/2010
    4                      1                      07/11/2010                 
    Below is the SQL Query
    SELECT
           MC.MC_ID as ID,
            MC.complete_Date as completed,
            MC.next_maint as nextDate,
            MC.maint_notes as Notes,
            MC.facility as Facility,
            M.EquipId,
            M.name as name,
            M.SerialNumber as SN,
            M.dept as dept,
            M.Freq as freq
            From  MC_Maintenance MC, Machine M
            where  MC.MC_ID =  M.MC_ID
    '           USING MAX(nextDate )
    Any ideas would help.
    TJ

    I would have thought that was a simple group by problem?
    SELECT M.EquipID, MC.MC_ID, Max(MC.next_maint)
    FROM MC_Maintenance MC INNER JOIN Machine M ON MC.MC_ID = M.MC_ID
    GROUP BY M.EquipID, MC.MC_ID

  • Web GUI new feature - creating a new record based on the current record

    Vincent,
    We need new feature in Web GUI:
    creating a new record based on the current record with data
    from Moscow with money

    It is already enabled, in the next release.
    If you joint TAB program, the march preview build contains it. User can select 1 or multiple users and make a copy.

  • Query range must return one record based on the amount passed.

    Hi,
    Need to return the correct line_number based on the amout that falls within that range.
    Example;- if current amount value is 100 then line_number should return 1.
    if current amount value is 420 then line_number should return 4.
    Line_Num Amount
    *1 149.99*
    2 300
    3 400
    *4 500*
    5 9999999.99
    I need this in a query to resolve this, not PL/SQL.
    Thanks in advance.

    select min(line_num) from yourtable where amount >= &input_amount

  • Different links in the detailed navigation, based on URL alias

    <u>What I'm trying to do :</u>
    Based on URL aliases /irj/portal/individual or /irj/portal/business
    I will dynamically add an UME group to the already logged in user.
    <u>Filter :</u>
    If clicking on /irj/portal/individual I will store "group=individual" in the context, and add UME group individual, if clicking /irj/portal/business I will store "group=business" in the context, and add UME group business and remove individual, and then redirect to the same URL.
    <u>Configuration</u>
    Each UME group has a one-to-one mapping to a Portal role.
    I will place an ACL on the PCD content, based on group, hiding/showing aggregated folders, hanging under the roles.
    <u>Wanted end-result</u>
    Different links in the detailed navigation, based on URL alias.
    <b>My question is how you would implement the filter part, mentioned above ?</b>
    Portal app or J2EE servlet filter or something else ?

    Hi sunil,
       Create a JSPDynPage component(C) having 2 hbj:link whose hrefs point to these 2 iViews(A and B). U can get the href of the iView by previewing it(for A and B). Create an iview from the par component (C) and add it to the DLN so that it shows the links to ur iViews(A and B). U can make the Show Tray property of this iView (C) to false.
    Regards,
    Harini S

  • Get Old Value and the new value based on the date

    Hi
    I have a table called roster created below with following insert statements.
    CREATE TABLE ROSTER
    ROSTER_EMPLOYEE_DEF_ID NUMBER,
    EMPLOYEE_ID NUMBER,
    DEFINITION_REGION_CODE NUMBER,
    DEFINITION_DISTRICT_CODE NUMBER,
    DEFINITION_TERRITORY_CODE NUMBER,
    START_DATE DATE,
    END_DATE DATE
    INSERT INTO ROSTER
    (ROSTER_EMPLOYEE_DEF_ID,EMPLOYEE_ID,DEFINITION_REGION_CODE,DEFINITION_DISTRICT_CODE,DEFINITION_TERRITORY_CODE,START_DATE,END_DATE)
    VALUES
    (1,299,222,333,444,'1-JUN-2011','30-JUN-2011')
    INSERT INTO ROSTER
    (ROSTER_EMPLOYEE_DEF_ID,EMPLOYEE_ID,DEFINITION_REGION_CODE,DEFINITION_DISTRICT_CODE,DEFINITION_TERRITORY_CODE,START_DATE,END_DATE)
    VALUES
    (2,299,223,334,445,'1-JUL-2011','20-JUL-2011')
    INSERT INTO ROSTER
    (ROSTER_EMPLOYEE_DEF_ID,EMPLOYEE_ID,DEFINITION_REGION_CODE,DEFINITION_DISTRICT_CODE,DEFINITION_TERRITORY_CODE,START_DATE,END_DATE)
    VALUES
    (3,299,224,335,446,'1-AUG-2011','30-AUG-2011')
    INSERT INTO ROSTER
    (ROSTER_EMPLOYEE_DEF_ID,EMPLOYEE_ID,DEFINITION_REGION_CODE,DEFINITION_DISTRICT_CODE,DEFINITION_TERRITORY_CODE,START_DATE,END_DATE)
    VALUES
    (4,300,500,400,300,'1-JUN-2011','20-JUN-2011')
    INSERT INTO ROSTER
    (ROSTER_EMPLOYEE_DEF_ID,EMPLOYEE_ID,DEFINITION_REGION_CODE,DEFINITION_DISTRICT_CODE,DEFINITION_TERRITORY_CODE,START_DATE,END_DATE)
    VALUES
    (5,300,501,401,301,'1-JUL-2011','20-JUL-2011')
    In the above table we have columns like
    EMPLOYEE_ID,DEFINITION_REGION_CODE,DEFINITION_DISTRICT_CODE,DEFINITION_TERRITORY_CODE,START_DATE,END_DATE
    The result i am looking from the above table is based on the EMPLOYEE_ID OF START_DATE AND END_DATE
    I need to get OLD_DEFINITION_REGION_CODE and the NEW_DEFINITION_CODE
    Similarly OLD_DEFINITION_REGION_CODE and the NEW_DEFINITION_REGION_CODE
    and OLD_DEFINITION_TERRITORY_CODE and the NEW_DEFINITION_TERRITORY_CODE
    I need to get one row of data for each employee saying old value and new value
    for employee 299 there are 3 records it must give the new record which is the latest date i.e start date 1-aug-2011 and end date 30-aug-2011 old record will be
    start date 1-jul-2011 and 20-jul-2011
    For the above table data i need to get the data as below
    EMPLOYEE_ID OLD_DEFINITION_REGION_CODE NEW_DEFINITION_CODE OLD_DEFINITION_REGION_CODE NEW_DEFINITION_REGION_CODE START_DATE END_DATE
    299 223 224 334 335 20-JUL-11 30-AUG-11
    300 500 501 400 401 20-JUN-11 20-JUL-11
    Please suggest me to get the above result based on the data. Please let me know if my posts are not clear
    Thanks
    Sudhir

    SELECT  EMPLOYEE_ID,
            OLD_DEFINITION_REGION_CODE,
            NEW_DEFINITION_REGION_CODE,
            OLD_DEFINITION_DISTRICT_CODE,
            NEW_DEFINITION_DISTRICT_CODE,
            OLD_DEFINITION_TERRITORY_CODE,
            NEW_DEFINITION_TERRITORY_CODE,
            START_DATE,
            END_DATE
      FROM  (
             SELECT  EMPLOYEE_ID,
                     ROW_NUMBER() OVER(PARTITION BY EMPLOYEE_ID ORDER BY START_DATE DESC) RN,
                     LAG(DEFINITION_REGION_CODE) OVER(PARTITION BY EMPLOYEE_ID ORDER BY START_DATE) OLD_DEFINITION_REGION_CODE,
                     DEFINITION_REGION_CODE NEW_DEFINITION_REGION_CODE,
                     LAG(DEFINITION_DISTRICT_CODE) OVER(PARTITION BY EMPLOYEE_ID ORDER BY START_DATE) OLD_DEFINITION_DISTRICT_CODE,
                     DEFINITION_DISTRICT_CODE NEW_DEFINITION_DISTRICT_CODE,
                     LAG(DEFINITION_TERRITORY_CODE) OVER(PARTITION BY EMPLOYEE_ID ORDER BY START_DATE) OLD_DEFINITION_TERRITORY_CODE,
                     DEFINITION_TERRITORY_CODE NEW_DEFINITION_TERRITORY_CODE,
                     LAG(END_DATE) OVER(PARTITION BY EMPLOYEE_ID ORDER BY START_DATE) START_DATE,
                     END_DATE
               FROM  ROSTER
      WHERE RN = 1
    EMPLOYEE_ID OLD_DEFINITION_REGION_CODE NEW_DEFINITION_REGION_CODE OLD_DEFINITION_DISTRICT_CODE NEW_DEFINITION_DISTRICT_CODE OLD_DEFINITION_TERRITORY_CODE NEW_DEFINITION_TERRITORY_CODE START_DAT END_DATE
            299                        223                        224                          334                          335                           445                           446 20-JUL-11 30-AUG-11
            300                        500                        501                          400                          401                           300                           301 20-JUN-11 20-JUL-11
    SQL>  SY.

  • How to get the pricing hierarchy based on the delivery date for sales order

    Hi,
    How to get the pricing hierarchy based on the delivery date for sales order other than system date.
    My requirement is to get the Pricing hierarchy based on the delivery date other than system date.
    Waiting for kind response.
    Best Regards,
    BDP

    HI Sai,
    please refer teh document already how to write FM based extration on generic extractors.
    and here  the logic to find the latest records values:-
    -> get the data in an internal table
    ->Sort the internal table data based from date descending
    -> Using READ statement , we can read the first record of the table which is nothign but your latest record.
    Regards.
    Sakthi

  • Calculate Avg  for the given months based on the no. of days in months

    Dear Experts
    I  have a report in which there is a characterictic claenderyr/month.The Input paramter is claenderyr/month which is restricted by a variable of type interval. i mean user will enter calenderyr/month as interval say 012010 to 06.2010. Now I have to calculate Avg sale Qty for the given months based on the no. of days for the given range of months. How I can achieve this in BW Query. Pl. advice
    Dinesh Sharma

    Hi,
    Create formula for the sales qty.
    maintain the exception aggregation as average based on calday
    Best Regards,
    M.H.REDDY

  • Don't include last page of the SSRS report based on the parameter.

    I created the report, which has 4 pages.
    Each page contains bunch of tables and charts, which display data in scope of dataset, created for each page and reflecting certain subject.
    Each page also has Header and Footer.
    My users requested, the report has possibility to include or not include data on Page #4.
    Other words, report should display 3 or 4 pages based on the entered parameter.
    1. I created parameter named  “Include #### metrics”, which contains options: Y, N
     2. For each object on the page 4 I added dependency on the selected 
    parameter in  the visibility option.
    Now if user select parameter Not include Page #4, report displays 3 pages as expected and page #4 is empty, but with Header and Footer.
    The problem: Their
    preference is to not to show page 4 at all if someone chooses to not to include
    #### metrics.
    My question is how to force the report to display just 3 selected pages.

    Hi MK0526,
    Per my understanding that you have add page break to make the report to display on three diferent pages and you want to show and hide the fourth page based on the parameter selected, now the issue is although the content on the fourth page have been hidden
    but the page header and page footer still display, right?
    I have tested on my local envoronment and can reproduce the issue, the issue can be caused by the page break you have set, you may have check the "Add a page break after", please find the details information below to reset the page break:
    Please create four rectangles and add all the content from each pages to include in each rectangle
    Please  check the "Add a page break before" for rectangle2, rectangle3,rectangle4  in the rectangle properties and not add any page break in the  first rectangle (Rectangle1)
    Add expression below to show/hide the rectangle4:
    =iif(Parameters!IncludePage4.Value="No",true,false)
    Now you will not see the page header and footer in the fourth page when you select "No" in the parameter.
    If you still have any problem, please feel free to ask.
    Regards
    Vicky Liu
    Vicky Liu
    TechNet Community Support

  • The "Details All" view in the SNP planning book is not sorted

    The "Details All" view in the SNP planning book should be sorted by Product Description in ascending order. 
    When all products in the selection ID are loaded into the SNP planning book, and then "Details All" is selected from the Header area, the product description list is not sorted in ascending order.
    However when I load small number of products the issue does not occur they get sorted correctly by product description.
    Is this hapenning due to standard functionality/Standard macro in Planning book?
    Please let me know if anybody has faced this kind of issue earlier.
    Edited by: Rohit Arun Bhosale on Jul 5, 2010 1:05 PM

    Hi Rohit,
    If you are using Detail All drill down then you wonu2019t get any option for sort as it will load all codes from the selection  in the planning book and sorting will be based on product IDs.
    but if you drill down from header on detail all -filter, even if you sort the display list there using ascending/descending button for Description, the list that you will get in the planning book after load will be based on the Product IDs agian.
    I hope this is controlled from the selection we do in planning book where we select Location/Product, but if your planning is better driven by the description then you can remove the Product ID selection from header setting and have only description in drill down.
    Regards,
    Digambar

  • SAP Standard report to view the asset balance- Based on the calender year

    Hi ALL
    Any sap standard programs are available to view the asset balance based on the calendar year not for the fiscal year. 
    Asset balance report S_ALR_87011964 will display based on the fiscal year in report date. For example I want to view the September month asset balance, Any standard report to view the calendar year wise output.
    Regards
    K.Gunasekar

    Dear Gunasekar,
    in Asset balance report S_ALR_87011964 you can view also a calendar year, you can enter every Reporting date in the progrm.
    In RABEWG_ALV01 you can enter also a Capitalization date "from to". I think this is what you want.
    regars Bernhard

  • When saving a file in [.jpg] format, i am asked to choose a quality from 1 to 100. what changes in the file created based on the quality parameter chosen?

    when saving a file in [.jpg] format, i am asked to choose a quality from 1 to 100. what changes in the file created based on the quality parameter chosen?. i would like to know what changes, so in the future i can set my camera to a setting that will give me the highest quality to begin with,allowing me to make crops and still preserve the quality.
    thank you
    dovid

    It's the level of compression. Lower number, more aggressive compression, more visual artifacts.
    Aside from that you should never use jpeg as a working format. The compression is destructive and cumulative, and the file deteriorates every time you resave it.
    Use TIFF or PSD, and if you need jpeg save out a copy as a single final step.

  • What is the  FM/BAPI  to get the Goods Receipt  Based on the Purchase Order

    Hi ,
    I want FM/BPI  to get the Goods Receipt  Based on the Purchase Order in MM.
    Thnx in advance

    Hi
    BAPI_GOODSMVT_CREATE
    Thanks & Regards
    Kishore

Maybe you are looking for

  • How do I remove images viewed using preview?

    Hi, I'm new to this forum and not very computer savvy, so please bear with me if in the wrong place or asking dumb questions or using wrong jargon! Still not quite understanding preview except that it seems the only way to see a bigger image of photo

  • Constant reboot after IOS4 upgrade Solved!

    I too was having the dreaded error 29 code and stuck in recovery mode along with the 5 minute constant reboot since upgrading to IOS4 two days ago. I had to use Blackra1n to get it out of recovery. Blackra1n will NOT jailbreak IOS4 but will fix the s

  • How to reconnect my ipod Classic

    How can I reconnect my ipod ( so that it shows up in itunes ) once I have ejected the ipod, without having to unplug and plug back in the USB connector? Thanks.

  • Odd Gvim behavior in Fluxbox

    I just started using gvim recently, and while it's a great editor, it has some weird resizing behavior. I'm not quite sure if it is gvim or fluxbox that is responsible, so I was wondering if anybody could help me stop it. Here's what happens: I start

  • Connection to Thunderbird was refused.

    On opening up Thunderbird noticed no emails for 2 days I'm told "Could not connect to mail server. Connection was refused." So cannot send/receive emails! Firefox is working o.k.