Help needed in building a tree without duplicatin​g the nodes

Iam trying to construct a tree, ID name as the parent node and channel name & channel values as its corresponding child nodes.
I had constructed the tree, but the problem i have is with interfacing that with in my  main program. In the main program say suppose I have 5 Id's, each Id has some X number of channel's. And each channel has a value.
Each Id is indexed and passed to the for loop. And since this for loop is inside the while loop each ID will be executed for every 5 iterations.
Id, channel names will be constant each time it gets executed, but the channel value's will be updated during run time.
If I directly feed the Id, channel names and values, replacing the constants in the vi, the tree is duplicating the messages, each time a ID is received inside the for loop, it is creating a new parent and child nodes.
Please help me in fixing this issue, and constructing the tree, where the ID and channel names are not not duplicated.For better understanding Iam attaching a snapshot shot, which tells at what point the ID, channel name array and value is received.
Attachments:
channel_info.vi ‏31 KB
channel.png ‏60 KB

Caleb Harris, the arbitration ID is not the same each time. Cluster has several different id's, this can be seen in the attached screen shot. Attached sreen shot shows the cluster information,  a sample ID unbundled from the array and the list of channels in that Arbitration ID. I got an idea how to construct the tree but for that,
1)Need to store all this arbitartion Id's,channel's , and values in 3- different arrays (Channel array and the values array must have the same size).
2)Channel array must be in synchronus with the Value array say like the first index value of the value_array  should represent the value of the first element of the channel    
   array, similarly the second index value of the value_array  should represent the value of the second element of the channel array and so on.
3) When ever the channel value gets updated, that particular element of the value array should be updated.
If I can do this 3- steps I think I can succesfully build a tree. Can you please take a look at the snapshot and help me out in doing this.
Attachments:
Cluster Image.PNG ‏67 KB

Similar Messages

  • Help needed with building Flex App without FlexBuilder

    Hi Guys,
    I was building my application on Struts framework with JSPs
    as the front end. I just got a new requirement to try and build my
    application's GUI with Flex (completely replacing JSPs). I cannot
    use FlexBuilder as my company won't buy it. I've been trying to dig
    through all articles and documentation to find out how to write
    MXML files and compile them without a FlexBuilder. I have learnt
    that I can write MXML files using plain notepad, but I am totally
    lost when it comes to understanding how to compile my MXML files
    with FlexBuilder. I know about the ant compiler and web compiler
    but How do I use them? I want to use the web compiler but how can I
    configure the Web Compiler to compile my MXML files when I run my
    app? Can someone kindly help me out.
    Thank You,
    TNJ

    You can use mxmlc to compile your mxml files into swfs.
    Google for mxmlc and there should be plenty information.

  • Help needed in constructing a tree

    Help needed in constructing a tree. I was wondering if some one can suggest me how to add messages in the second column for both the parent node and child elements.
    I was able to create a tree succefully, but want to add some description in the second column for the first column elements, for both parent and child elements.
    Please suggest me how to add the arrays to second column for parent and child nodes.
    Solved!
    Go to Solution.
    Attachments:
    Tree_fix.vi ‏15 KB

    The Child Text parameter is the one you are searching for. It accepts a 1D string array for the following columns.
    hope this helps,
    Norbert
    CEO: What exactly is stopping us from doing this?
    Expert: Geometry
    Marketing Manager: Just ignore it.

  • Help needed Displaying ALV  Secondary list without using oops concept

    Hi Experts
    Help needed Displaying ALV  Secondary list without using oops concept.
    its urgent
    regds
    rajasekhar

    hi chk this code
    ******************TABLES DECLARATION*****************
    TABLES : VBAP,MARA.
    *****************TYPE POOLS**************************
    TYPE-POOLS : SLIS.
    ****************INTERNAL TABLES**********************
    DATA : BEGIN OF IT_VBAP OCCURS 0,
    VBELN LIKE VBAP-VBELN, "SALES DOCUMENT
    POSNR LIKE VBAP-POSNR, "SALES DOCUMENT ITEM
    MATNR LIKE VBAP-MATNR, "MATERIAL NUMBER
    END OF IT_VBAP.
    ****************TEMPORARY VARIABLES******************
    DATA : V_VBELN LIKE VBAP-VBELN."SALES DOCUMENT
    DATA : V_MTART LIKE MARA-MTART. "MATERIAL TYPE
    *****************FIELD CATALOG***********************
    DATA : IT_FIELDCAT TYPE SLIS_T_FIELDCAT_ALV,
           WA_FIELDCAT TYPE SLIS_FIELDCAT_ALV.
    ****************LAYOUT*******************************
    DATA : WA_LAYOUT TYPE SLIS_LAYOUT_ALV.
    ***************VARIANT*******************************
    DATA : G_VARIANT LIKE DISVARIANT.
    ****************SAVE*********************************
    DATA : G_SAVE(1) TYPE C.
    *****************EVENTS******************************
    DATA : XS_EVENTS TYPE SLIS_ALV_EVENT,
           G_EVENTS TYPE SLIS_T_EVENT.
    ******************PF STATUS**************************
    DATA : PF_STATUS TYPE SLIS_FORMNAME VALUE 'SET_PF_STATUS'.
    ******************USER COMMAND************************
    DATA : USER_COMMAND TYPE SLIS_FORMNAME VALUE 'SET_USER_COMMAND',
           R_UCOMM LIKE SY-UCOMM.
    ****************SELECTION SCREEN************************
    SELECT-OPTIONS : S_VBELN FOR VBAP-VBELN.
    ***************AT SELECTION SCREEN*********************
    AT SELECTION-SCREEN.
      PERFORM VALIDATE.
    **************START-OF-SELECTION**************************
    START-OF-SELECTION.
      PERFORM GET_DETAILS.
      PERFORM FIELDCAT.
      PERFORM LAYOUT.
      PERFORM VARIANT.
      PERFORM SAVE.
      PERFORM EVENTS.
      PERFORM ALV_DISPLAY.
    *********************FORMS*******************************************
    *&      Form  validate
          text
    -->  p1        text
    <--  p2        text
    FORM VALIDATE .
      SELECT SINGLE VBELN
                    FROM VBAP
                    INTO V_VBELN
                    WHERE VBELN IN S_VBELN.
      IF SY-SUBRC <> 0.
        MESSAGE E000 WITH 'enter valid vbeln'.
      ENDIF.
    ENDFORM.                    " validate
    *&      Form  get_details
          text
    -->  p1        text
    <--  p2        text
    FORM GET_DETAILS .
      SELECT VBELN
             POSNR
             MATNR
             FROM VBAP
             INTO TABLE IT_VBAP
             WHERE VBELN IN S_VBELN.
      IF SY-SUBRC <> 0.
        MESSAGE E000 WITH 'no details found'.
      ENDIF.
    ENDFORM.                    " get_details
    *&      Form  fieldcat
          text
    -->  p1        text
    <--  p2        text
    FORM FIELDCAT .
      WA_FIELDCAT-TABNAME = 'IT_VBAP'.
      WA_FIELDCAT-FIELDNAME = 'VBELN'.
      WA_FIELDCAT-OUTPUTLEN = 10.
      WA_FIELDCAT-SELTEXT_L = 'SALES DOC'.
      APPEND WA_FIELDCAT TO IT_FIELDCAT.
      CLEAR WA_FIELDCAT.
      WA_FIELDCAT-TABNAME = 'IT_VBAP'.
      WA_FIELDCAT-FIELDNAME = 'POSNR'.
      WA_FIELDCAT-OUTPUTLEN = 6.
      WA_FIELDCAT-SELTEXT_L = 'ITEM'.
      APPEND WA_FIELDCAT TO IT_FIELDCAT.
      CLEAR WA_FIELDCAT.
      WA_FIELDCAT-TABNAME = 'IT_VBAP'.
      WA_FIELDCAT-FIELDNAME = 'MATNR'.
      WA_FIELDCAT-OUTPUTLEN = 18.
      WA_FIELDCAT-SELTEXT_L = 'MATERIAL NO'.
      APPEND WA_FIELDCAT TO IT_FIELDCAT.
      CLEAR WA_FIELDCAT.
    ENDFORM.                    " fieldcat
    *&      Form  LAYOUT
          text
    -->  p1        text
    <--  p2        text
    FORM LAYOUT .
      WA_LAYOUT-ZEBRA = 'X'.
    ENDFORM.                    " LAYOUT
    *&      Form  VARIANT
          text
    -->  p1        text
    <--  p2        text
    FORM VARIANT .
      CLEAR G_VARIANT.
      G_VARIANT-REPORT = SY-REPID.
    ENDFORM.                    " VARIANT
    *&      Form  SAVE
          text
    -->  p1        text
    <--  p2        text
    FORM SAVE .
      CLEAR G_SAVE.
      G_SAVE = 'A'.
    ENDFORM.                    " SAVE
    *&      Form  EVENTS
          text
    -->  p1        text
    <--  p2        text
    FORM EVENTS .
      CLEAR XS_EVENTS.
      XS_EVENTS-NAME = SLIS_EV_TOP_OF_PAGE.
      XS_EVENTS-FORM = 'TOP_OF_PAGE'.
      APPEND XS_EVENTS TO G_EVENTS.
    ENDFORM.                    " EVENTS
    *&      Form  TOP_OF_PAGE
          text
    FORM TOP_OF_PAGE.
      WRITE :/ ' INTELLI GROUP'.
    ENDFORM.                    "TOP_OF_PAGE
    *&      Form  ALV_DISPLAY
          text
    -->  p1        text
    <--  p2        text
    FORM ALV_DISPLAY .
      CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY'
       EXPORTING
      I_INTERFACE_CHECK              = ' '
      I_BYPASSING_BUFFER             =
      I_BUFFER_ACTIVE                = ' '
         I_CALLBACK_PROGRAM             = SY-REPID
         I_CALLBACK_PF_STATUS_SET       = PF_STATUS
         I_CALLBACK_USER_COMMAND        = USER_COMMAND
      I_STRUCTURE_NAME               =
         IS_LAYOUT                      = WA_LAYOUT
         IT_FIELDCAT                    = IT_FIELDCAT
      IT_EXCLUDING                   =
      IT_SPECIAL_GROUPS              =
      IT_SORT                        =
      IT_FILTER                      =
      IS_SEL_HIDE                    =
      I_DEFAULT                      = 'X'
         I_SAVE                         = G_SAVE
         IS_VARIANT                     = G_VARIANT
         IT_EVENTS                      = G_EVENTS
      IT_EVENT_EXIT                  =
      IS_PRINT                       =
      IS_REPREP_ID                   =
      I_SCREEN_START_COLUMN          = 0
      I_SCREEN_START_LINE            = 0
      I_SCREEN_END_COLUMN            = 0
      I_SCREEN_END_LINE              = 0
    IMPORTING
      E_EXIT_CAUSED_BY_CALLER        =
      ES_EXIT_CAUSED_BY_USER         =
        TABLES
          T_OUTTAB                       = IT_VBAP
       EXCEPTIONS
         PROGRAM_ERROR                  = 1
         OTHERS                         = 2
      IF SY-SUBRC <> 0.
        MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
                WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
    ENDFORM.                    " ALV_DISPLAY
    *&      Form  SET_PF_STATUS
          text
    FORM SET_PF_STATUS USING EXTAB TYPE SLIS_T_EXTAB.
      SET PF-STATUS 'Z50651_PFSTATUS' EXCLUDING EXTAB.
    ENDFORM.                    "SET_PF_STATUS
    *&      Form  SET_USER_COMMAND
          text
    FORM SET_USER_COMMAND USING R_UCOMM
                                RS_SELFIELD TYPE SLIS_SELFIELD.
      CASE R_UCOMM.
        WHEN 'DC'.
          READ TABLE IT_VBAP INDEX RS_SELFIELD-TABINDEX.
          IF SY-SUBRC = 0.
            SELECT SINGLE MTART
                          FROM MARA
                          INTO V_MTART
                          WHERE MATNR = IT_VBAP-MATNR.
            IF SY-SUBRC <> 0.
       MESSAGE E000 WITH 'NO MATERIAL DESCRIPTION FOR SELECTED MATERIAL NO'.
            ELSE.
              WRITE :/ 'MATERIAL NO :',IT_VBAP-MATNR.
              WRITE :/ 'MATERIAL TYPE :' , V_MTART.
            ENDIF.
          ENDIF.
        WHEN 'BACK'.
          LEAVE TO SCREEN 0.
        WHEN 'EXIT'.
          LEAVE TO SCREEN 0.
        WHEN 'CLOSE'.
          CALL TRANSACTION 'SE38'.
      ENDCASE.
    REPORT  Z_ALV_INTERACTIVE  MESSAGE-ID ZMSG_50651
                                    LINE-SIZE 100
                                    LINE-COUNT 60
                                    NO STANDARD PAGE HEADING.
    ******************TABLES DECLARATION*****************
    TABLES : VBAP,MARA.
    *****************TYPE POOLS**************************
    TYPE-POOLS : SLIS.
    ****************INTERNAL TABLES**********************
    DATA : BEGIN OF IT_VBAP OCCURS 0,
    VBELN LIKE VBAP-VBELN, "SALES DOCUMENT
    POSNR LIKE VBAP-POSNR, "SALES DOCUMENT ITEM
    MATNR LIKE VBAP-MATNR, "MATERIAL NUMBER
    END OF IT_VBAP.
    ****************TEMPORARY VARIABLES******************
    DATA : V_VBELN LIKE VBAP-VBELN."SALES DOCUMENT
    DATA : V_MTART LIKE MARA-MTART. "MATERIAL TYPE
    *****************FIELD CATALOG***********************
    DATA : IT_FIELDCAT TYPE SLIS_T_FIELDCAT_ALV,
           WA_FIELDCAT TYPE SLIS_FIELDCAT_ALV.
    ****************LAYOUT*******************************
    DATA : WA_LAYOUT TYPE SLIS_LAYOUT_ALV.
    ***************VARIANT*******************************
    DATA : G_VARIANT LIKE DISVARIANT.
    ****************SAVE*********************************
    DATA : G_SAVE(1) TYPE C.
    *****************EVENTS******************************
    DATA : XS_EVENTS TYPE SLIS_ALV_EVENT,
           G_EVENTS TYPE SLIS_T_EVENT.
    ******************PF STATUS**************************
    DATA : PF_STATUS TYPE SLIS_FORMNAME VALUE 'SET_PF_STATUS'.
    ******************USER COMMAND************************
    DATA : USER_COMMAND TYPE SLIS_FORMNAME VALUE 'SET_USER_COMMAND',
           R_UCOMM LIKE SY-UCOMM.
    ****************SELECTION SCREEN************************
    SELECT-OPTIONS : S_VBELN FOR VBAP-VBELN.
    ***************AT SELECTION SCREEN*********************
    AT SELECTION-SCREEN.
      PERFORM VALIDATE.
    **************START-OF-SELECTION**************************
    START-OF-SELECTION.
      PERFORM GET_DETAILS.
      PERFORM FIELDCAT.
      PERFORM LAYOUT.
      PERFORM VARIANT.
      PERFORM SAVE.
      PERFORM EVENTS.
      PERFORM ALV_DISPLAY.
    *********************FORMS*******************************************
    *&      Form  validate
          text
    -->  p1        text
    <--  p2        text
    FORM VALIDATE .
      SELECT SINGLE VBELN
                    FROM VBAP
                    INTO V_VBELN
                    WHERE VBELN IN S_VBELN.
      IF SY-SUBRC <> 0.
        MESSAGE E000 WITH 'enter valid vbeln'.
      ENDIF.
    ENDFORM.                    " validate
    *&      Form  get_details
          text
    -->  p1        text
    <--  p2        text
    FORM GET_DETAILS .
      SELECT VBELN
             POSNR
             MATNR
             FROM VBAP
             INTO TABLE IT_VBAP
             WHERE VBELN IN S_VBELN.
      IF SY-SUBRC <> 0.
        MESSAGE E000 WITH 'no details found'.
      ENDIF.
    ENDFORM.                    " get_details
    *&      Form  fieldcat
          text
    -->  p1        text
    <--  p2        text
    FORM FIELDCAT .
      WA_FIELDCAT-TABNAME = 'IT_VBAP'.
      WA_FIELDCAT-FIELDNAME = 'VBELN'.
      WA_FIELDCAT-OUTPUTLEN = 10.
      WA_FIELDCAT-SELTEXT_L = 'SALES DOC'.
      APPEND WA_FIELDCAT TO IT_FIELDCAT.
      CLEAR WA_FIELDCAT.
      WA_FIELDCAT-TABNAME = 'IT_VBAP'.
      WA_FIELDCAT-FIELDNAME = 'POSNR'.
      WA_FIELDCAT-OUTPUTLEN = 6.
      WA_FIELDCAT-SELTEXT_L = 'ITEM'.
      APPEND WA_FIELDCAT TO IT_FIELDCAT.
      CLEAR WA_FIELDCAT.
      WA_FIELDCAT-TABNAME = 'IT_VBAP'.
      WA_FIELDCAT-FIELDNAME = 'MATNR'.
      WA_FIELDCAT-OUTPUTLEN = 18.
      WA_FIELDCAT-SELTEXT_L = 'MATERIAL NO'.
      APPEND WA_FIELDCAT TO IT_FIELDCAT.
      CLEAR WA_FIELDCAT.
    ENDFORM.                    " fieldcat
    *&      Form  LAYOUT
          text
    -->  p1        text
    <--  p2        text
    FORM LAYOUT .
      WA_LAYOUT-ZEBRA = 'X'.
    ENDFORM.                    " LAYOUT
    *&      Form  VARIANT
          text
    -->  p1        text
    <--  p2        text
    FORM VARIANT .
      CLEAR G_VARIANT.
      G_VARIANT-REPORT = SY-REPID.
    ENDFORM.                    " VARIANT
    *&      Form  SAVE
          text
    -->  p1        text
    <--  p2        text
    FORM SAVE .
      CLEAR G_SAVE.
      G_SAVE = 'A'.
    ENDFORM.                    " SAVE
    *&      Form  EVENTS
          text
    -->  p1        text
    <--  p2        text
    FORM EVENTS .
      CLEAR XS_EVENTS.
      XS_EVENTS-NAME = SLIS_EV_TOP_OF_PAGE.
      XS_EVENTS-FORM = 'TOP_OF_PAGE'.
      APPEND XS_EVENTS TO G_EVENTS.
    ENDFORM.                    " EVENTS
    *&      Form  TOP_OF_PAGE
          text
    FORM TOP_OF_PAGE.
      WRITE :/ ' INTELLI GROUP'.
    ENDFORM.                    "TOP_OF_PAGE
    *&      Form  ALV_DISPLAY
          text
    -->  p1        text
    <--  p2        text
    FORM ALV_DISPLAY .
      CALL FUNCTION 'REUSE_ALV_LIST_DISPLAY'
       EXPORTING
      I_INTERFACE_CHECK              = ' '
      I_BYPASSING_BUFFER             =
      I_BUFFER_ACTIVE                = ' '
         I_CALLBACK_PROGRAM             = SY-REPID
       I_CALLBACK_PF_STATUS_SET         = PF_STATUS
         I_CALLBACK_USER_COMMAND        = USER_COMMAND
      I_STRUCTURE_NAME               =
         IS_LAYOUT                      = WA_LAYOUT
         IT_FIELDCAT                    = IT_FIELDCAT
      IT_EXCLUDING                   =
      IT_SPECIAL_GROUPS              =
      IT_SORT                        =
      IT_FILTER                      =
      IS_SEL_HIDE                    =
      I_DEFAULT                      = 'X'
         I_SAVE                         = G_SAVE
        IS_VARIANT                      = G_VARIANT
         IT_EVENTS                      = G_EVENTS
      IT_EVENT_EXIT                  =
      IS_PRINT                       =
      IS_REPREP_ID                   =
      I_SCREEN_START_COLUMN          = 0
      I_SCREEN_START_LINE            = 0
      I_SCREEN_END_COLUMN            = 0
      I_SCREEN_END_LINE              = 0
    IMPORTING
      E_EXIT_CAUSED_BY_CALLER        =
      ES_EXIT_CAUSED_BY_USER         =
        TABLES
          T_OUTTAB                       = IT_VBAP
       EXCEPTIONS
         PROGRAM_ERROR                  = 1
         OTHERS                         = 2
      IF SY-SUBRC <> 0.
        MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
                WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
      ENDIF.
    ENDFORM.                    " ALV_DISPLAY
    *&      Form  SET_PF_STATUS
          text
    FORM SET_PF_STATUS USING EXTAB TYPE SLIS_T_EXTAB.
      SET PF-STATUS 'STANDARD' EXCLUDING EXTAB.
    ENDFORM.                    "SET_PF_STATUS
    *&      Form  SET_USER_COMMAND
          text
    FORM SET_USER_COMMAND USING R_UCOMM
                                RS_SELFIELD TYPE SLIS_SELFIELD.
      CASE R_UCOMM.
        WHEN 'DC'.
          READ TABLE IT_VBAP INDEX RS_SELFIELD-TABINDEX.
          IF SY-SUBRC = 0.
            SELECT SINGLE MTART
                          FROM MARA
                          INTO V_MTART
                          WHERE MATNR = IT_VBAP-MATNR.
            IF SY-SUBRC <> 0.
       MESSAGE E000 WITH 'NO MATERIAL DESCRIPTION FOR SELECTED MATERIAL NO'.
            ELSE.
              WRITE :/ 'MATERIAL NO :',IT_VBAP-MATNR.
              WRITE :/ 'MATERIAL TYPE :' , V_MTART.
      SUBMIT SLIS_DUMMY WITH P_MATNR EQ IT_VBAP-MATNR
                        WITH P_MTART EQ V_MTART.
            ENDIF.
          ENDIF.
        WHEN 'BACK'.
          LEAVE TO SCREEN 0.
        WHEN 'EXIT'.
          LEAVE TO SCREEN 0.
        WHEN 'CLOSE'.
          CALL TRANSACTION 'SE38'.
      ENDCASE.
    plz reward if useful

  • Help needed in building query

    Tab1
    Parent       Child       sa l
    P1     A1       4000
    A1     A       1000
    A1     B       4000
    A     X       1000
    A     Y         2000
    B     X1        1000           
    B     X2       3000I need to build a query that will retrieve the value for each child as the sum of the salaries of all its child in a single query.
    That is
    For Sal P1 = Sal A1 + all child of A1 and its child
         For A1 = Sal A1 + all child of A1 and its child ( A+B+X+Y+X1+X2)
    Like it should sho all the records with the count .. please help

    This is not so simple since it is not really clear in your data set whether the sal belongs to the parent or to the child. I assume it's the salary of the child, in which case the salary of P1 is missing. The best option is to fix the data model and have two tables: one containing the element and sal, and another table containing just the relationships. To fix this issue I introduced a dummy record for P1 and salary 0.
    SQL> with t2 as
      2  ( select connect_by_root(child) cbr
      3         , sal
      4      from (select * from t union all select null,'P1',0 from dual)
      5   connect by parent = prior child
      6  )
      7  select cbr child
      8       , sum(sal)
      9    from t2
    10   group by cbr
    11  /
    CHILD    SUM(SAL)
    X1           1000
    A1          16000
    X2           3000
    P1          16000
    Y            2000
    X            1000
    A            4000
    B            8000
    8 rows selected.Regards,
    Rob.

  • I need to build an executable which allows all the VIs to be viewed as if in LabView

    I hope I am not being stupid but I need to build an executable which allows all the VIs to be viewed, opened - closed, as if being interpreted by LabView 8.5. The system is a simulator and I am required to allow the system to be inspected for correctness whilst running. Further, interactive panels exist at various locations throughout the structure and they must all work.
    Can somebody tell me how to do this or provide me with some pointers?
    Ideally I would like the navigation to be the same as if the code was being operated within LabView then the same idiots guide, I’ll need it in two years, will work for both the exe and the interpreted versions. The target machines will not run LabView and simply distributing the VI tree would be very bad news because it would allow erroneous edits to break the system.
    Thanks in advance

    Mike
    Sorry I may not have expressed myself well.
    I have developed the system in LabView 8.5 and I now want to release it to be installed on machines without LabView. I can do that, however I have a problem. I am required to allow the internals (the source) of the system to be visable; I don’t know how to do that without LabView on the machine. Yes, I know I could produce PDFs for all 1500+ VIs but I don’t want to do that and the customer does not want it eather; he wants to navigate the model and check what he finds.
    I hope this makes my requirements clearer.
    Thanks
    Frank

  • Help Needed in Building JTree

    HI,
    I've a doubt in Building a JTree.It wud be helpful if some one helps me with a better logic for building this Tree..
    I have a tree like this:
    root
    |
    A--B--C--D
    A--B--C--D
    A--B--C
    A--B--C--E--F
    I have the tree nodes like this . i need to merge the nodes like this
    root
    |
    A
    |
    -- B
    |
    --C
    |
    --D
    --E
    |
    --F
    I've tried it in few ways. It doesn't seems to be working.. Can some one help me in giving me a better logic in doing this

    Hello,
    When updating the tree, do not access the tree nodes directly. Update the tree via its (TreeModel).
    to get the model of your JTree use
    DefaultTreeModel treeModel = (DefaultTreeModel)myTree.getModel();to add nodes use the method
    treeModel.insertNodeInto(newChild,parent,offset);and remove nodes using
    treeModel.removeFromParent(nodeToRemove);--
    Regards,
    Ahmed Saad

  • Urgent help needed in building an expression

    hi,
    I am using expression editor to build the following simple expression.
    "if inputvalue = 0 then 10 else 20"
    so Far I have used various forms of "IF" and "CASE" statements but could not successfully create the expression.Could not find anything useful in the help docs as well.
    any help asap would be highly appreciated..highly disappointed with OWB which does not allow to build such a simple expression and the user docs as well are very poor.

    Hi,
    There is something you need to know up front on expressions and transformations. Expressions are SQL expressions, whereas transformations are pl/sql.
    Looking at your pseudo code, you are trying to do a procedural thing. So there are 2 ways of doing this. One is correctly the case statement. For an example on how to do this go to the OWB sample code page on OTN (http://otn.oracle.com/sample_code/products/warehouse/content.html) where an explanation is given on how to do this. It includes an example metadata file for you to evaluate.
    The other way of doing this is in PL/SQL, in which case you would create a small function accepting in parameter and then doing the procedural language on that. To create this use the create functions activity in OWB. Here you will get a nice code editor (similar to the expression builder) to guide you in the creation of this function.
    Hope this helps,
    Jean-Pierre

  • Help needed to build delete statement

    i need to keep last 10 days data+ last day of everymonth data in my table.
    this table will grow on daily basis.
    ex:
    data_date no.of records
    2006/02/28 10000
    2006/03/31 11000
    2006/04/30 12000
    2006/05/31 13000
    2006/06/09     13100
    2006/06/10 13200
    2006/06/11 13300
    2006/06/12 13400
    2006/06/13     13500
    2006/06/14     13600
    2006/06/15 13700
    2006/06/16 13800
    2006/06/17     13900
    2006/06/18     14000
    means last 10 days + last day of evermonth data need to store and remaining all
    records i need to delete from this table.
    could you help me to build this delete statement in single statement.

    select * from mytbl;
    DD                 NR
    28-02-2006      12000
    31-03-2006      10000
    30-04-2006      12050
    31-05-2006       9500
    06-06-2006      13100
    07-06-2006      13200
    08-06-2006      13300
    09-06-2006      13400
    10-06-2006      13500
    11-06-2006      13600
    12-06-2006      13700
    13-06-2006      13800
    14-06-2006      13900
    15-06-2006      14000
    16-06-2006      14100
    17-06-2006      14200
    18-06-2006      14300
    17 rows selected.
    delete from mytbl
    where not
    ( dd = last_day( dd ) -- Keep last days of months
       or  dd >= trunc(sysdate) - 10 -- Keep last 10 days
    3 rows deleted.
    select * from mytbl;
    DD                 NR
    28-02-2006      12000
    31-03-2006      10000
    30-04-2006      12050
    31-05-2006       9500
    09-06-2006      13400
    10-06-2006      13500
    11-06-2006      13600
    12-06-2006      13700
    13-06-2006      13800
    14-06-2006      13900
    15-06-2006      14000
    16-06-2006      14100
    17-06-2006      14200
    18-06-2006      14300To me...it looks like it does work!

  • Urgent help : Need to recover a database without backup and archivelogs

    Hi,
    We are in urgent need to recover a database without backup and archivelogs
    one datafile seems corrupted
    SQL> recover automatic database until cancel using BACKUP CONTROLFILE;
    ORA-00279: change 10527325422479 generated at 07/27/2011 03:13:04 needed for
    thread 1
    ORA-00289: suggestion : /pys/u5/oradata/PYS/PYSarch/arch0001.0000181845.arc
    ORA-00280: change 10527325422479 for thread 1 is in sequence #181845
    ORA-00278: log file '/pys/u5/oradata/PYS/PYSarch/arch0001.0000181845.arc' no
    longer needed for this recovery
    ORA-00308: cannot open archived log
    '/pys/u5/oradata/PYS/PYSarch/arch0001.0000181845.arc'
    ORA-27037: unable to obtain file status
    HP-UX Error: 2: No such file or directory
    Additional information: 3
    Specify log: {<RET>=suggested | filename | AUTO | CANCEL}
    CANCEL
    ORA-01547: warning: RECOVER succeeded but OPEN RESETLOGS would get error below
    ORA-01152: file 1 was not restored from a sufficiently old backup
    ORA-01110: data file 1: '/pys/u2/oradata/PYS/pay_system_01.dbf'

    N Gasparotto wrote:
    bsac14 wrote:
    my database is in no archive mode
    can you please tell how to restore
    yes it is a datafile corruptionYou did not say how you defined that's a datafile corruption. You provide minimum to zero information.
    I just need to bring the database up,no need any exact data
    I can refresh from prod laterThen drop and recreate database. Basically and since you are not in archive mode, no recover is possible. Period.
    Nicolas.Hi,
    How did you come to the conclusion that your datafile is corrupted? Can you provide and supported logs?
    Regards .....

  • HELP NEEDED ON BUILDING HTMLDB APP

    Hello,
    I am very new to HTMLDB and building an application. I have the HTML already developed using Macromedia and I have some styles and Javascripts, I would like to use this piece of HTML and HTMLDB's functionality,
    The first thing I wanna do is I want to create a login for users of my site, I have many questions here, would appreciate if someone can answer me,
    1. I would prefer using the login process from the sample application, but at the same time, my application would require concepts like users mapped to groups, that I create and only people in certain groups should be able to see certain pages or links, is it better to use HTMLDB's admin or should I create a custom process? would appreciate if someone can point me on a doc or help to implement the login process with custom html page.
    2. Where will I input all my CSS, UI images, and what would the src to the files be in html if I upload the same using HTMLDB, I know its done some where but not able to figure out,
    3. Would really be great, if someone can first get me started with rendering an HTML page with above criterias and it would be awsome if I can have a login page working. Thanks

    Hello,
    Take a look at the howtos section
    http://www.oracle.com/technology/products/database/application_express/howtos/index.html
    or the studio
    http://htmldb.oracle.com/pls/otn/f?p=18326:1
    or the wiki
    http://wiki.shellprompt.net/bin/view/Apex/
    or the Oracle By Example
    http://www.oracle.com/technology/obe/obe10gdb/develop/htmldb/htmldb.htm
    There's quite a bit of info out there that should help get you going in the right direction.
    For your second question it how you link in your files depends if you have access to the filesystem or not. If you have access to the filesystem it's usally somethign like #IMAGE_PREFIX#, if you've uploaded through the UI it's either #WORKSPACE_IMAGES# or #APP_IMAGES# followed by the image name.
    Carl

  • Help needed to build simple BRF

    Hi,
    I am new to BRF and wanted some help from you building a simple BRF, say a look up from the database table.

    Hi,
    I guess you are trying to use BRF function from custom application and not talking about Process-Controlled Workflow.
    Yes. You can use BRF from custom application. BRF is just one of functions delivered in NetWeaver level.
    http://help.sap.com/saphelp_scm70/helpdata/EN/9a/6b67ce7c26446483af079719edf679/frameset.htm
    http://help.sap.com/saphelp_scm70/helpdata/EN/d6/38bb4006d9cc38e10000000a155106/frameset.htm
    Regards,
    Masa

  • Lost Newbie, help needed for building dream machine

    Hello everyone!
    I was wondering if you could tell me what you think about this setup for premiere, after effects and speed grade use:
    http://pcpartpicker.com/user/trundrumbalind/saved/#savedbuild_167634
    I know it's probably an overkill, but what do you guys think?

    First off, I would not go for that particular discrete sound card: It is not sufficiently better in quality than onboard audio to justify the $58 cost. What's more, that card is not a true X-Fi card at all; in fact, it is basically a descendant of the old software-based Ensoniq AudioPCI, which (mis)uses the CPU for most audio tasks (there is a controller chip on that card, but that chip is very similar to the codec-based onboard audio).
    Second, the RAM and motherboard are both overkill. In fact, you might not be able to run all four sticks of RAM at anywhere near its DDR3-2133 speed. Intel (and JEDEC) officially limit the maximum memory speed with a fully-populated memory controller to only DDR3-1333 speed. You can run that memory at the DDR3-2133 speed using an XMP profile - but then, you're limited to running only two sticks of RAM total at that speed. Besides, that quad-channel kit is really meant for LGA 2011 platforms, not LGA 1155 platforms. And the motherboard actually costs as much money as or more money than many good X79 LGA 2011 motherboards. Remember, the LGA 1155 platform has only two memory controller channels, not four. The official JEDEC spec allows the implementation of up to four ranks per memory controller channel - albeit at only up to DDR3-1333 speed. With DDR3-1600 and higher-speed RAM as well as all RAM running using XMP profiles, JEDEC officially limits such operation to only two ranks per channel (one double-sided DIMM, such as in all 8GB DIMMs, already eats up two ranks per slot).
    In other words, that setup is a waste of money at that price point. Why spend $2600+ on a limited LGA 1155 build when you could have gotten a superior-performing LGA 2011 build with an i7-3930K for the same price or slightly less? As a matter of fact, I would personally not spend more than about $2000 for LGA 1155.

  • Help needed!! Why do I keep losing the connection to my cRIO?

    Hi All,
    I've got a real time system with the following setup.
    I have got a cRIO out in the field running a real time application that accquires data from various thermocouples and sends the data to the my host computer over a wireless radio link. I am using a wireless ethernet modem with a data transfer rate of 100 kb/sec. The modem is being shared by 12 other radios also transmitting data to the host PC.
    So, basically, I've got the host PC on one end and 13 field computers (one of which is my cRIO running a real-time application) on the other end. The 13 field computers are sending data to the host PC over wireless radio links utilizing a single wireless ethernet modem. The data from the 13 radios is placed on a que and the modem cycles through the que enabling the data from each radio to pass through one at a time.
    My real time application is sampling the thermocouple data every 1 sec and sending it across to the host application via a shared variable
    The host PC is also running an application that acts as the user interface.
    My problem is this:
    My system runs OK for a couple of minutes and then suddenly I lose the conection to the cRIO. Once this happens, I have to manually reset the cRIO (i.e. cycle the power back on) to re-establish the connection. This is both tiresome and inconvenient as the system needs to be able to run continuously for several hrs.
    What could be the possible causes for this loss in connection? Is it possible that a clash between signals causes the modem to drop the connection to the cRIO? If so, is there a way to monitor the connection between the host and cRIO and automatically reset the cRIO in the event of a lost connection?
    Any help would be highly appreciated.
    Thanks,
    Taizoon

    Thanks for the suggestions. I think I was overflowing my FIFO so it may be a memory issue. However, it dies hard when I place a probe on my FIFO read data. Since this seems to be repeatable, NI may be able to look into it.
    Anyways, I'll try some of my own troubleshooting and your suggestions then if I'm still having problems I'll be sure to check back.
    CLA, LabVIEW Versions 2010-2013

  • Help needed for building report with execution method Java Concurrent prog

    Hi,
    I have saw a report like this:
    The report has executable "XML Publisher Data Template Executable", short name as "XDODTEXE", application "XML Publisher",execution method "Java Concurrent program". Also the report has a XML publisher Data Template and Data definition and in the data definition a .xml file is attached.
    I could not understand what is the data source?
    Could anyone help me on how to build or update this type of report?
    Is there any link or help docs which has proper step by step procedure to build this type of xml publisher report?
    Please help.
    Thanks.

    The xml file which is attached to the data definition is the data source and it has sql queries and structure of xml file.
    Check this out for step-by-step guidance.
    http://www.oracle.com/technetwork/middleware/bi-publisher/overview/xmlebsrep-132947.pdf
    http://apps2fusion.com/at/ps/51-prabhakar/262-xml-publisher-and-data-template-sql-query-to-develop-bi-publisher-reports
    For more on data templates refer user guide
    http://download.oracle.com/docs/cd/E10415_01/doc/bi.1013/e12187/T421739T434255.htm

Maybe you are looking for