Create Favourate for table content

Hi,
Jdev 11.1.1.5.0
I've created a tree structure from a single DB table using self-reference. I can select the required nodes from this tree and clcik on command button, then will display a table with the selected nodes information. Till this part, i've achieved.
Now the tricky thing is, I want to save this table as a favourate with a name (Ex: German-Business Management) in a dropdown.Another user can save his/her favourate with another name(Indian-Business Management).
Tomorrow, If i click on any favourate, the corresponding results should be displayed in table format.
Could you please suggest some pointers or suggestion on my usecase?
Thanks,
Samba.

Thanks John.
Sure...I tried to provide more details as per your suggestion. Please let me know, if still need more information.
As I need to create table & calculation part in two regions at a time from the tree. I've used programatic Contextual Events concept to create table. Till this, It's working as per expectation. Iam creating the create from ArrayList which is prepopulated beans.
If user clicks on 'Save' command button, system need to ask for the name to save content of selected nodes as a favourate in a dropdown. Here Iam looking for suggestion on best option to save the selected nodes information.
Following is the code for Contextual Event controller
=======================================================
public void handleEvent(Object payload){
ActionEvent actionEvent = (ActionEvent)payload;
UIComponent component = (UIComponent)actionEvent.getSource();
List rows = (ArrayList)component.getAttributes().get("selectedRows");
FacesContext context = FacesContext.getCurrentInstance();
ELContext elContext = context.getELContext();
Application app = context.getApplication();
ExpressionFactory expFactory = app.getExpressionFactory();
handleSelectedDocsRegion(elContext,expFactory,rows);
handleEstimationRegion(elContext,expFactory,rows);
public void handleSelectedDocsRegion(ELContext elContext,ExpressionFactory expFactory, List rows){
List selectedRows = new ArrayList();
ValueExpression valueExp = expFactory.createValueExpression(elContext, "#{pageFlowScope.SelectedDocsBean}", Object.class);
SelectedDocsBean bean = (SelectedDocsBean)valueExp.getValue(elContext) ;
if(bean == null){
return;
Iterator iterator = rows.iterator();
while( iterator.hasNext() ){
Row row = (Row)iterator.next();
String childItemId = (String)row.getAttribute("ChildItemId");
SelectedRow sRow = new SelectedRow(childItemId,"YYYY");
selectedRows.add(sRow);
bean.setSelectedList(selectedRows);
AdfFacesContext adfContext = AdfFacesContext.getCurrentInstance();
adfContext.addPartialTarget(bean.getSelectedTable());
public void handleEstimationRegion(ELContext elContext,ExpressionFactory expFactory, List rows){
ValueExpression valueExp = expFactory.createValueExpression(elContext, "#{pageFlowScope.EstimationCostBean}", Object.class);
EstimationCostBean bean = (EstimationCostBean)valueExp.getValue(elContext) ;
if(bean == null){
return;
Iterator iterator = rows.iterator();
System.out.println("ROWS SIZE"+rows.size());
while( iterator.hasNext() ){
Row row = (Row)iterator.next();
bean.setFiles(rows.size());
AdfFacesContext adfContext = AdfFacesContext.getCurrentInstance();
adfContext.addPartialTarget(bean.getNumberOfFiles());
Following is the code for Event publisher
===========================================
DCIteratorBinding iterBind= (DCIteratorBinding)bContainer.get("HierLinks1Iterator");
String ChildItemId = (String)iterBind.getCurrentRow().getAttribute("ChildItemId");
String checkboxConfirmedStatus = (String)iterBind.getCurrentRow().getAttribute("checkboxConfirmedStatus");
Boolean checkboxConfirmed = (Boolean)iterBind.getCurrentRow().getAttribute("checkboxConfirmed");
Row[] outerRows = iterBind.getAllRowsInRange();
for (Row row : outerRows) {
Boolean checkboxConfirmed = (Boolean)row.getAttribute("checkboxConfirmed");
if(checkboxConfirmed == true){
selectedRows.add(row);
traverseTree(row,selectedRows);
public void traverseTree(Row node,List selectedRows){
//List selectedRows = new ArrayList();
ViewRowSetImpl viewRowImpl = (ViewRowSetImpl)node.getAttribute("LeafHierLinks");
if(viewRowImpl != null){
Row[] rows = viewRowImpl.getAllRowsInRange();
for (Row row : rows) {
String innerChildItemId = (String)row.getAttribute("ChildItemId");
String innerCheckboxConfirmedStatus = (String)row.getAttribute("checkboxConfirmedStatus");
Boolean innerCheckboxConfirmed = (Boolean)row.getAttribute("checkboxConfirmed");
if(innerCheckboxConfirmed == true){
selectedRows.add(row);
-Samba.

Similar Messages

  • How to create variant for table/view ?

    Hi,
    When I go through SM30, I find a radio button called variant. I don't know the effect.
    Can anyone tell me how to create variant for table / view ?
    I want to know when we need to create variant for table/view.
    Best regards,
    Chris Gu

    hi ,
    Whenever you start a program in which selection screens are defined, the system displays a set of input fields for database-specific and program-specific selections. To select a certain set of data, you enter an appropriate range of values.
    For further information about selection screens, refer to Selection Screens in the ABAP User's Guide.
    If you often run the same program with the same set of selections (for example, to create a monthly statistical report), you can save the values in a selection set called a variant
    Procedure
    To create a new variant:
           1.      On the ABAP Editor initial screen, enter the name of the program for which you want to create a variant, select Variants, and choose Change.
           2.      On the variant maintenance initial screen, enter the name of the variant to be created.
    Note the naming convention for variants (see below).
           3.      Choose Create.
    If the program has more than one selection screen, a dialog box for screen assignment appears. The dialog box does not appear if the program only has one selection screen. The selection screen appears in this case.
           4.      If there is more than one selection screen, select the screens for which you want to create the variant
    5.      Choose Continue.
    The (first) selection screen for the report appears.
    If your program has more than one selection screen, use the scroll buttons in the left-hand corner of the application toolbar to navigate between them and to fill the fields with values. If you keep scrolling forwards, the Continue button appears on the last selection screen.
           6.      Enter the desired selection values, including multiple selection and dynamic selection.
           7.      Choose Continue.

  • Creating Tcode for Table

    hi Experts,
      Can any one Help meplz, I'm Venkat,I have doubt in Dictionary .i.e how to create transaction code for database table .when i create Tcode for table in Se93 ,it asks abt progarm name,if i given that name as table name it is giveng run time error.

    Hi
    You can create new Tcode from Tcode SE93
    Fill all the attributes
    Give your custom txn name 'ZTXN'.
    Give the Short text for it .... (This short text will appear if u choose this txn as favourites on SAP Easy access)...
    Select the Object type of your program from the 5 radiobuttons that come up..Select 2nd option if its a report program. Press Enter.
    When you go to the next screen, Enter name of the Program(ZPROG) you are intending to make the transcation for ...
    Save the Transaction.
    Now you can type the transaction ... 'ZTXN' in the command bar that will take you to the selection screen of the program ZPROG...
    Regards

  • Create transaction for table

    Hi experts,
    Can anybody help how to create transaction for table maintenance generation?
    Thanks in advance,
    Zak.

    Hi
    Check this:
    Table maintennace generator is used to create screen to maintain values in a table. Once you create maint generator you can goto transaction SM30 and add data to table . In SAP it is more relevant to customizing data.
    Create a table maintance program for a z table :
    In transaction SE11, in the attribute tab of your z table check table maintenance check box. Go to SM30 transaction, enter the ztable name and click on maintain button. Here you can enter new entries into the ztable .
    Or
    You can create a PARAMETER TRANSACTION for the transaction for SM30 .
    Follow these steps :
    1. go to transaction SE93 , give your own transaction code say ztran_tab, for maintaining your ztable.
    2. Click on create button and check the radio button Transaction with parameters (PARAMETER TRANSACTION) and click on the tick button.
    3. In the next screen enter default values:
    transaction : SM30
    check the check box skip initial screen
    4. Scroll down you will find a table control for default values
    Name of the screen field | value
    VIEWNAME | your ztable name
    SHOW | X
    Save your work.
    Now as you have created a custom transaction for maintaining your ztable this transaction can be called from any program with CALL transaction 'XXX'.
    Regards,
    Vishwa.

  • How to create transaction for table maintinance generator

    what is the procedure(steps) to create transaction for a table maintinance generator

    Hi,
    The link will be useful for ur requirement.
    allaboutsap.blogspot.com/2007/04/table-maintenance-in-sap-step-by-step.html
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/8129f164-0a01-0010-2a8e-8765287250fc
    REgards,
    Sarosh

  • Create UDF for table not in the List of tables

    Hi all,
    I know that my question maybe easy or been asked before, but I couldn't find the answer.
    To create a UDF in SAP B1 version 9.0 you should go Tools -> Customization Tools -> User-Defined Fields - Management...
    which is ok and working perfect. but my question is:
    If I want to create UDF for a table not in the list of tables there what should I do? I need to create 2 UDFs for table OMRC [Manufacturers], and can't find it in master data tables.
    anyone had this issue before?
    EDIT  : Is it good to add the field by using sql server? I know it's possible, but will it be visible in SAP
    thank you
    Message was edited by: Samira Haroun

    Hi Samira,
    There is noit a simple link for this, I advise you to study the documentation for TB1300 SBO Development Certification.
    Ypu should also have knowledge of .net, and C# or VB, because you have to make a small program/addon to add the fields
    Kind regards
    Ad Kerremans

  • Create pagination for table contain more than 2 PK

    Guys;
    Is there any way to use the wizard for creating FORM PAGINATION for tables having more than 2 PK??
    Regards;

    Hi dimitri;
    after the user login & start using this form thiswhat should happen to these 3 PKs:
    -1st PK will be a unique number for the questions.
    -2nd PK should be the ID for each survey ( created as global variable in Zero Page ).
    -3rd PK will be the division for this user (also created as a global variable in ZERO PAGE)..so this is the only field which will nt be changed while the user is logged..
    i tried to use the 1st 2 PKs...& set the last one to get a default value..it worked in the begining but gave me the 1st record for each Survey but my problem that i couldnt navigate to the 2nd record..& after that once i log out & relogin it willnt give me anything.
    Regards;
    ehammad

  • Create URL for image content and display in new window

    Hi,
    I am attaching a new image and it is displayed in a table view.
    I am having problems creating the URL for the image.
    When i give the link of external site like http://www.google.com, it works fine. It does not work when i give as www.google.com.
    It does not work for the image. Please help.
      ls_properties-name         = 'KW_RELATIVE_URL'.
      ls_properties-value        = lv_imgname.
      APPEND ls_properties TO lt_properties.
      ls_properties-name         = 'LANGUAGE'.
      ls_properties-value        = sy-langu.
      APPEND ls_properties TO lt_properties.
    Assign file properties
      ls_file_access_info-binary_flg = 'X'.
      ls_file_access_info-file_name  = lv_imgname.
      ls_file_access_info-mimetype   = 'image/pjpeg'.
      ls_file_access_info-property   = lv_string2.
      APPEND ls_file_access_info TO lt_file_access_info.
    Move content to file_content
      lv_str = lv_img_content.
      lv_strlen   = XSTRLEN( lv_str ).
      lv_offset   = 1022.
      lv_bytes_rd = 0.
      lv_bytes_rm = lv_strlen.
      ASSIGN lv_str TO <fs>.
      WHILE lv_bytes_rd LT lv_strlen.
        IF  lv_bytes_rm LT lv_offset.
          ls_content-line = <fs>+lv_bytes_rd(lv_bytes_rm).
        ELSE.
          ls_content-line = <fs>+lv_bytes_rd(lv_offset).
        ENDIF.
        APPEND ls_content TO lt_content.
        lv_bytes_rd = lv_bytes_rd + lv_offset.
        lv_bytes_rm = lv_strlen - lv_bytes_rd.
        CLEAR ls_content.
      ENDWHILE.
    Create a Document using class CL_CRM_DOCUMENTS
      CALL METHOD cl_crm_documents=>create_with_table
        EXPORTING
          business_object     = ls_business_object
          properties          = lt_properties
          file_access_info    = lt_file_access_info
          file_content_binary = lt_content
          raw_mode            = 'X'
        IMPORTING
          loio                = ls_loio
          phio                = ls_phio
          error               = ls_error.
    Using the logical and physical id's, get the file location as an URL
    data:
    lv_no type char1 value '1'.
        CALL METHOD cl_crm_documents=>get_with_url
          EXPORTING
            loio     = ls_loio
            phio     = ls_phio
            url_type = '2'
          IMPORTING
            error    = ls_error
            url      = lv_url1.
    should i prefix the url with 'javascript:'?
    Thanks in advance.
    Regards
    Shanthi

    Hi Shanti,
    The URLs that are external to the server, you should always have http://, your image URL is has http:// prefix? Other wise system will always look for the same inside the current BSP application. For Example your BSP application is ZBSP and if you are accessing www.google.com the URL in the browser will be
    *******/bsp/ZBSP/www.google.com which will not be existing, hence causing the problem.
    If not try adding http:// to the URL by concatenation and try.
    Regards,
    Ravi

  • Creating transaction for tables

    Hai,
    This is very urgent, pls give me an idea for converting table into a transaction.
    ie, by running transaction the particular table should display the contents.

    Hi,
    Table Maintenance generator is required to do Manual entries in the Table.
    If the requirement is to update the table only programmatically
    and not manually then table maint generator is not required.
    Manual entries in table can be maintained ( New record can be inserted / existing can be modified )
    using transaction SM 30, if the table maintenance for the table is generated.
    http://help.sap.com//saphelp_470/helpdata/EN/a7/5133ac407a11d1893b0000e8323c4f/frameset.htm
    How to activate Table maint.
    Goto SE11 and open the table.
    Click UTILITIES -> Table Maint. Generator, Enter the details and click on Save. Then activate the table.
    chk a sample 1.
    refer.
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/com.sap.km.cm.docs/library/abap/how%20to%20implement%20events%20in%20table%20maintenance.doc
    how to create a a T-code of that
    Go to se93.
    Then create the new T.code.
    Under that select parameter Transaction.
    Then give the sm30 in the t.code in default values tab.
    check the checkbox skip initial screen.
    in classification tab.
    click checkbox inherit gui attributes..
    Now below..
    In the default values..
    WRITE
    viewname = give ur table name.
    show = X
    save and check it once...
    now u can able to call ur table through ur new t.code...
    Regards,
    Padmam.

  • Create entry for table FILENAMECI

    Hi,
    I want to create physical file path for my logical file in table FILENAMECI.
    The problem is this table allows maintenance with restriction the I cannot maintain through SE16 or SM30 (for V_FileName).
    Please let me know how can I create new entry for this table.
    Thanks,
    Khanh

    Use view V_FILENACI!
    Thread close!

  • Please help for create index for table in db2

    Dear Consultants,
    Our Production Servers have a problem, when user input materials in t-code VA01, the check data take long time to complete.
    I was create a incident on SAP Portal and they recommended to create a new index on table:
    VBRP in the order MANDT, AUBEL and AUPOS.
    but we don't sure how to do this, please help us !
    The SAP consultant message:
    " It was identified that there is one SQL statement which was
    responsible for the majority of the time spent during the VA01
    transaction. It accounted for around 49 seconds.
    The SQL statement was analysed and a selectivity analysis was carried
    out on certain fields specified in the WHERE clause. The statement is
    currently executed via a full table scan which is not an efficient
    access. It is therefore recommended to create a new index on table
    VBRP in the order MANDT, AUBEL and AUPOS. "
    Our System Landscape IS : DEV -> QAS -> Production and DataBase server : db2 9.07 , SAP ECC 6.0, windows server 2008
    Thanks and Best Regards,
    Hien Nguyen

    Hi Deepak,
    Could you please tell me the places where can i post the message for ABAPer, i don't know to choose : ABAP Development , ABAP Testing and Troubleshoo… or somthing else
    Sorry for my amateur !
    Thanks you very much.
    Best Regards,
    Hien

  • Tips on creating website for online content on ipad

    Hi there I am not sure this is the right forum but here goes my question. I am building a simple website (text and pictures with slideshows) and my objective is to be able to show it to clients on the ipad without necessarily being connected to the internet. What is the best way to go forward? I was thinking of buidling it on iweb and somehow transferring it to the ipad for offline browsing, any other tips? how would I transfer the whole website to the ipad? thanx in advance
    Claudio

    I could be wrong, but I don't believe that Safari, at least, will load pages locally. I would instead suggest creating your document as a Keynote or PowerPoint presentation and showing it with Keynote for iPad or another presentation app, or creating it as a PDF.
    Regards.

  • Create schedule for the Content Categorizer.

    Hi, all!
    I want to do a schedule for the automatically recatecorization (with Content Categorizer Component) of documents.
    I need to run this task automatically, for all documents, for some documents, and/or for some folders, every day, for example.
    How i can do this?
    Thanks for the tips!

    Actually, if you want to run a batch categorization, it'll be more like a command-line call, than a service call. I'd expect that the documentation provides some hints.
    If you want to do your own custom categorizer engine, you might analyse services called, or you could also take a look at ContentCategorizer component in Component Wizard (note: to view standard components, you need to clone them to a custom component first).

  • How to create query for tables with many to many relationship

    in my sql i'm unable to update the table using select clause...is there any way to update a table which is in many to many relationship.
    Ex:1st table student(student_id int primary key auto_increment, student_name varchar(30));
    2nd table contact (contact_id int primary key auto_increment, c_email varchar(40));
    3rd table student_contact(student_id int references student, contact_id int references contact);
    i would like to auto insert the both two columns in the student_contact while the student and the contact table being updated automatically.

    This is a JSP/JSTL forum, not a SQL forum. If you're using MySQL, better use their own forums at dev.mysql.com.
    I'll give some hints anyway: learn about SQL JOIN. In general there is good SQL documentation available at the website of the RDBMS manfacturer. Go check it out. There is also a nice SQL tutorial at w3schools.com. Good luck.

  • Tx code for tables ?

    How to create Transaction for Tables ?plz telme ?

    Hi,
    1. you need generate the table maintenance using the Menu Utilities->Table maintenance generator
    2. give the authorization group, package, function group, overview screen number etc.
    3.create the table maintenance
    4. now go to se93
    5. give custom tcode and say create
    then enter description , and then
    choose the radio button Transaction with parameters
    6. now enter tcode as SM30 and check the check box skip intial screen
    7. Check all gui support buttons
    8. now go down and enter VIEWNAME from F4 help and value as table name
    9. and add UPDATE(choose it from F4) and value as 'X'.
    VIEWNAME ZTABLE
    UPDATE X
    and save it, now check the Tcode.
    <b>Friendly Note: </b>You have many open threads, Plz close the threads if they are solved/answered. Plz reward points to the people who are helping you.
    Thanks
    Vinay

Maybe you are looking for

  • How to apply the constraint ONLY to new rows

    Hi, Gurus:    I have one question as follows:    We need to migrate a legacy system to a new production server. I am required to add two columns to every table in order to record who updates the row most recently through triggers, and  I should apply

  • Any way to get hotmail in the menubar?

    I have both gmail accounts and hotmail account (also a yahoo account) for email. I already use a menu item to check gmail, is there anything that can do the same thing for hotmail?

  • When using twitter fon application, I keep getting the error message....

    local cache db error (no such table:direct_messages) What does this mean and how do I correct it? I am not an experienced user and I just spontaneously tried to reply to a tweet.

  • Folder with question mark popping up when I turn on my Mac

    A little water spilled on my Mac acouple days ago. I let it dry for about 36 hours and it turned on again but a folder with a question mark comes up and flashes. A friend of mine told me that I need to install the iOS software that it came with. Unfo

  • Deleting photos off iphoto causing it to crash

    When i try and delete a photo on iphoto, it crashes the application, causing me to force quit. My trash is allready empty so that shouldnt be an issue. Any ideas or help? thanks