Remove_column( ) of cl_wd_table not returning back the column reference

Am using the remove_column( ) of cl_wd_table to remove a particular table column & also get the reference of a the same for inserting at a different position. But the system doesn't return back any value. I tried doing a get_column( ) before doing the remove_column( ) but even that wasn't able to get the reference to that column. I debugged & observed that the system was internally reading an internal table ME->ch_COLUMNS to get the list of columns but this table was empty and so the READ was failing.
method GET_COLUMN.
  CLEAR the_COLUMN.
  IF index > 0.
   READ TABLE ME->ch_COLUMNS INDEX index INTO the_COLUMN.
  ELSE.
   READ TABLE ME->CH_COLUMNS WITH KEY TABLE_LINE->ID = ID INTO
   THE_COLUMN.
  ENDIF.
endmethod.
I had bound the TABLE to a context node based on dictionary structure SCARR & 3 fields CARRNAME, CARRCODE & URL.  Please advise as to why the column references aren't available.
Uday

Hi Suman,
Thanks for the reply.
In WDDOMODIFYVIEW I have put the below coding:
method WDDOMODIFYVIEW .
  check first_time = abap_true.
  wd_this->gr_table ?= view->get_element( id = 'TABLE' ).
endmethod.
I need to change the table column position when the user clicks on a pushbutton. The attribute context_element is an importing parameter of type if_wd_context_element and have declared gr_table in view attributes as of type CL_WD_TABLE.  The coding is as below:
method ONACTIONMOVE_DOWN .
  data: old_index type i,
        new_index type i,
        lr_column type ref to cl_wd_table_column.
  old_index = context_element->get_index( ).
  check old_index < 3.
  lr_column = wd_this->gr_table->get_column( index = old_index ).
  wd_this->gr_table->remove_column( index = old_index ).
  new_index = old_index + 1.
  wd_this->gr_table->add_column( the_column  = lr_column
                                 index       = new_index ).
endmethod.
By the way I have noticed something else while debugging inside the standard code for get_column( ). The ME->CH_COLUMNS is empty but there is another attribute ME->CH_GROUPED_COLUMNS which has the type ref info for the 3 columns which am displaying in the TABLE. I haven't set anything specific properties for the table either. Any inputs from your side would be very useful.
Edited by: Uday on Aug 29, 2008 11:09 AM

Similar Messages

  • I'm having all sorts of connection issues on a iPhone i brought in the uk 6 months ago. am i able to use a genius bar abroad as I'm not returning to the uk?

    i brought a iphone 5 back in feb/march and since then its slowley getting worse and worse, my wifi hardly pickes up any signals and when it does they drop out all the time. my girlfriends iphone4 picks up and has no trouble holding onto the wifi, whilst sitting at the same table mine shows no signals. Im not returning to the uk any time soon so i want to know if its possible to visit an apple store for replacement abroad? im only 6 months into my apple care so i wouldnt think this should pose an issue. any help would be fantastic
    many thanks

    they will not repair the device in the us you must send it back to the country of purchase or set up repair through them the uk apple car number is as follows (44) 0844 209 0611*** you should be able to set up a mail repair through them

  • A rowset based on the SQL command was not returned by the OLE DB provider.

    Hi
    I am calling a stored procedure using ssis.
    i am creating a work table--temp in the procedure and using that to join and select columns from other tables.
    i am gettig the error
    [Positions [22612]] Error: A rowset based on the SQL command was not returned by the OLE DB provider.
    please help

    SET NOCOUNT ON 
    in the stored procedure and try again.
    Best Regards,Uri Dimant SQL Server MVP,
    http://sqlblog.com/blogs/uri_dimant/
    MS SQL optimization: MS SQL Development and Optimization
    MS SQL Consulting:
    Large scale of database and data cleansing
    Remote DBA Services:
    Improves MS SQL Database Performance
    SQL Server Integration Services:
    Business Intelligence

  • Return all the column values using the F4IF_INT_TABLE_VALUE_REQUEST

    Hi,
    How to return all the column values using the F4IF_INT_TABLE_VALUE_REQUEST?
    For example : if the row has 3 columns then after selecting the particular row, the RETURN_TAB internal table should contain all the three column values.
    Regards,
    Raghu

    Hi,
       Try the following...
    DATA : it_fields like help_value occurs 1 with header line.
    data: begin of w_vbap,
            vbeln      like vbap-vbeln,    
            posnr      like vbap-posnr,   
            werks      like vbap-werks,  
          end of w_vbap.
    data: i_vbap   like w_vbap   occurs 0 with header line,
             w_fields type help_value,
          i_dfies type table of dfies,
          i_return_tab type table of ddshretval with header line,
          i_field  type dfies.
      select vbeln posnr werks
          from vbap into table i_vbap up to 5 rows.
    if sy-subrc = 0.
       sort i_vbap by vbeln.
    endif.
      clear it_fields[] , it_fields.
      it_fields-tabname = c_vbap.
      it_fields-fieldname = 'VBELN'.
      it_fields-selectflag = c_on.
      append it_fields.
      it_fields-tabname = c_vbap.
      it_fields-fieldname = 'POSNR'.
      it_fields-selectflag = space.
      append it_fields.
      it_fields-tabname = c_vbap.
      it_fields-fieldname = 'WERKS'.
      it_fields-selectflag = space.
      append it_fields.
      loop at it_fields into w_fields.
        i_field-tabname   = w_fields-tabname.
        i_field-fieldname = w_fields-fieldname.
        i_field-keyflag   = w_fields-selectflag.
        append i_field to i_dfies.
      endloop.
      call function 'F4IF_INT_TABLE_VALUE_REQUEST'
        exporting
          retfield               = 'VBELN'
         window_title           = 'Select'
        tables
          value_tab              = i_vbap
          field_tab                = i_dfies
          return_tab             = i_return_tab
       exceptions
         parameter_error        = 1
         no_values_found        = 2
         others                 = 3
      read table i_return_tab into w_return_tab index 1.
      if sy-subrc = 0.
      endif.
    Regards,
    Srini.

  • Read from sql task and send to data flow task - [OLE DB Source [1]] Error: A rowset based on the SQL command was not returned by the OLE DB provider.

    I have created a execut sql task -
    In that, i have a created a 'empidvar' variable of string type and put sqlstatement = 'select distinct empid from emp'
    Resultset=resultname=0 and variablename=empidvar
    I have added data flow task of ole db type and I put this sql statement under sql command - exec emp_sp @empidvar=?
    I am getting an error.
    [OLE DB Source [1]] Error: A rowset based on the SQL command was not returned by the OLE DB provider.
    [SSIS.Pipeline] Error: component "OLE DB Source" (1) failed the pre-execute phase and returned error code 0xC02092B4.

    shouldnt setting be Result
    Set=Full Resultset as your query returns a resultset? also i think variable to be mapped should be of object type.
    Then for data flow task also you need to put it inside a ForEachLoop based on ADO.NET recordset and map your earlier variable inside it so as to iterate for every value the sql task returns.
    Also if using SP in oledb source make sure you read this
    http://consultingblogs.emc.com/jamiethomson/archive/2006/12/20/SSIS_3A00_-Using-stored-procedures-inside-an-OLE-DB-Source-component.aspx
    Please Mark This As Answer if it helps to solve the issue Visakh ---------------------------- http://visakhm.blogspot.com/ https://www.facebook.com/VmBlogs

  • My PC does not return to the source document I print from

    I had a setting control for
    this in XP but can't find the page I got it from.<o:p></o:p>
    <o:p> </o:p>
    In ANY application or browser
    this happens.  I print from a specific Excel workbook, by example, when I
    have a number of them open.  The system does not return to the workbook I
    printed from.  This is maddening and causes all kinds of issues.
     Searching the web for this now produces nothing and I know I can't be the
    only person who experiences this.<o:p></o:p>
    <o:p> </o:p>
    This is a Windows 7 platform
    in a networked business environment.  I'm running the Classic Menu add-in
    from Addintools because I can't stand the ribbon and have never liked it.
     In Windows 7, I'm running a couple of other add-ins that restore the XP
    use of the task bar properly so one can work efficiently.<o:p></o:p>
    <o:p> </o:p>
    None of the add-ins are what
    is causing this issue because I'd run the same Classic Menu add-in on the XP
    box and it had the same issue until I found the work-around that I can't
    remember now.<o:p></o:p>
    <o:p> </o:p>
    Has anyone else experienced
    this issue?<o:p></o:p>
    <o:p> </o:p>
    Jeff Lynch<o:p></o:p>

    Hi,
    "I print from a specific Excel workbook, by example, when I
    have a number of them open.  The system does not return to the workbook I
    printed from."
    If I'm not misunderstanding, do you mean that the workbook is automatically closed after you print from that workbook, right?
    As I know, if we use the default ribbon in Excel, no matter in Windows XP or Windows 7, the opened workbook should be stay opened after you print from that Excel workbook.
    So the question is that: what is the version of office? What is the Classic Menu add-in you're running now? Did you manually download and install it to your system? Could you please share a picture with us about the add-ins you're using?
    Yolanda Zhu
    TechNet Community Support

  • I need to download all of my photos from my iPhone 4S and my iPad 2 to my MacBook Air. I want to make sure all my photos are not lost and that they do not return to the original devices because of the cloud. Can someone please help ?

    I need to download all of my photos from my iPhone 4S and my iPad 2 to my MacBook Air because there is no more storage space available. I want to make sure all my photos are not lost and that they do not return to the original devices because of the cloud. Can someone please help ?

    Connect your devices to the computer with the USB cable (one device at a time) and import the photos via iPhoto or Image Capture.
    If you have not changed any default settings on your computer, iPhoto will automatically launch when you plug in the device. Then follow the import prompts.

  • My Mini Ipad Does not return to the Home screen after I press the Home button

    My Mini Ipad Does not return to the Home screen after I press the Home button. I have also tried to turn it off and it is not responding.

    Check the following:
    1. Check credit card number
    2. Check security code
    3. Billing Address must be the same as credit card
    4. Check expiry date
    5. Make sure you have sufficient fund

  • Iphone 5  Does not return to the Home screen after you press the Home button, Iphone 5  Does not return to the Home screen after you press the Home button

    Does not return to the Home screen after you press the Home button

    The buttons do wear out, and when they do you'd need to get the phone serviced.  

  • RowSetIterator not returning all the rows

    Hi,
    We have a use-case where we need to create a new row iterator to insert rows(values) in it. Immediately after insertRow(), we are reading the values by creating a secondary row set iterator (createRowSetIterator) but it is not returning all the inserted rows. Here is the code snippet:
    Code to insert rows:
    public void insertTerrLineOfBusiness(CreateOperation operation, TerritoryVORowImpl newTerritoryRow, TerritoryVORowImpl selectedRow){     
    if((operation.equals(CreateOperation.CREATE))
    || operation.equals(CreateOperation.COPY)
    || operation.equals(CreateOperation.ADD_EXISTING)){
    RowIterator selTerritoryLineOfBusinessIter = selectedRow.getTerritoryLineOfBusiness();
    //RowIterator newTerrLineOfBusinessIter = newTerritoryRow.getTerritoryLineOfBusiness();
    ViewRowSetImpl newTerrLineOfBusinessIter = (ViewRowSetImpl) newTerritoryRow.getTerritoryLineOfBusiness();
    newTerrLineOfBusinessIter.setAssociationConsistent(true);
    while(selTerritoryLineOfBusinessIter.hasNext()){
    TerritoryLineOfBusinessVORowImpl selTerrLineOfBusinessRow =
    (TerritoryLineOfBusinessVORowImpl)selTerritoryLineOfBusinessIter.next();
    TerritoryLineOfBusinessVORowImpl newTerrLineOfBusinessRow =
    (TerritoryLineOfBusinessVORowImpl)newTerrLineOfBusinessIter.createRow();
    newTerrLineOfBusinessRow.setTerritoryVersionId(newTerritoryRow.getTerritoryVersionId());
    newTerrLineOfBusinessRow.setLobCode(selTerrLineOfBusinessRow.getLobCode());
    newTerrLineOfBusinessIter.insertRow(newTerrLineOfBusinessRow);
    Code to read:
    public List getTerritoryLobsValues() {
    List <String> lobsValues = new ArrayList<String>();
    if (this.getTerritory().getCurrentRow() != null) {
    TerritoryVORowImpl territoryVORowImpl =
    (TerritoryVORowImpl)this.getTerritory().getCurrentRow();
    if(territoryVORowImpl.getTerritoryLineOfBusiness() != null){
    ViewRowSetImpl territoryLob =
    (ViewRowSetImpl)territoryVORowImpl.getTerritoryLineOfBusiness();
    RowSetIterator itr = territoryLob.createRowSetIterator(null);
    if(itr!=null){
    while(itr.hasNext()) {
    Row r = itr.next();
    String lobCode = (String)r.getAttribute("LobCode");
    lobsValues.add(lobCode);
    itr.closeRowSetIterator();
    return lobsValues;
    Can anybody suggest what could be the issue? How to fix it?
    Thanks,
    Akhila

    Thanks for your response.
    Jdev version:
    Primary == FUSIONAPPS_PT.V1REL6INT_LINUX.X64_120719.0800 (Primary Product for the view)
    Primary depends on FMWTOOLS == FMWTOOLS_11.1.1.6.0_GENERIC_120112.0037.2
    FMWTOOLS depends on label == JDEVADF_11.1.1.6.0_GENERIC_111205.1733.6192.1
    The above label originated from base label == JDEVADF_11.1.1.6.0_GENERIC_111205.1733.6192
    Use case: We have a tree table, each record may or may not have Line of Business(LOB) associated with it. On creating a child node in the tree table, the child node copies all the attributes of parent. These attributes are not committed explicitly, if user wants to save the child node only then the attributes are committed.
    Giving secondary rowSetIterator a name did not help in resolving this issue.
    If I am calling postChanges() before reading from secondary row iterator then its returning all the inserted values. But this.getTransaction().postChanges() is a JAudit violation, so cannot use it:
    RuleId: apps-jbo-category.File.AdfModel.54
    Rule: insertTerrLineOfBusiness - Review DBTransaction.postChanges call to ensure passivation-safety
    Any pointers on this?

  • Messaging Server 4.1: Received mail is not returned to the sender if the receiving local account does not exist.

    I have found that received mail is not returned to the sender if the receiving
    local account does not exist. This problem occurs even if I use Console to
    enable the Return message to sender option under the error handling methods.
    In addition, I have used the configutil
    to confirm that I have set the value
    for Unknown account action to "13," which corresponds to the settings "Return
    message to sender," "Notify the postmaster via email," and "Log the error in
    the log file." Yet, in this situation, an error message is being sent to
    postmaster, but not to the sender, and the error is not being recorded in the
    log file.
    <P>
    Do the following steps:<BR>
    <P>
    <OL>
    <LI>From Console, open the appropriate Messaging Server.
    <LI>Click the Configuration tab.
    <LI>Open the Services folder.
    <LI>Select SMTP.
    <LI>Click the System tab.
    </OL>
    <P>
    Check the "Domain handled by this server exclusively" field to make sure that
    your mail domain is listed. If your mail domain is not listed, then Messaging
    Server will assume that there is another mail server that is handling the
    domain listed and will forward requests to this server.
    <P>
    For more information, please see the document <I>Messaging Server
    Administrator's Guide</I>, Chapter 3, Configuring SMTP Services at <BR>
    http://docs.iplanet.com/docs/manuals/messaging/nms41/ag/smtp.htm#1010371

    On Thu, 12 Dec 2013 16:16:02 +0000, lpphiggp wrote:
    > I'm seeing this XTCOM error occur all over our /var/log/messages for one
    > server, running SLES11sp2 / OES11/sp1;
    >
    > I don't really know what this is even for. We don't use NetStorage or
    > iPrint even, this server only does basic NCP file serving, DHCP, and
    > hosts a GroupWise PO.
    > Is this anything to be concerned about?
    If this:
    http://www.linuxquestions.org/questi...entication-vs-
    edirectory-825043/
    is to be believed, it seems to indicate that your NAM configuration on
    this server is not valid. I'm not seeing this message here on the OES
    servers I looked at, and NAM is working correctly here.
    David Gersic dgersic_@_niu.edu
    Knowledge Partner http://forums.netiq.com
    Please post questions in the forums. No support provided via email.
    If you find this post helpful, please click on the star below.

  • Discoverer  report does not sum up the column

    Hi All,
    I am running the discoverer report from discoverer desktop and was
    trying to use the sum function to sum the total amount of the report.
    The sum function does not work and it only display Cell
    Sum: (blank) with no actual data.
    When i checked the report details some columns are calculated based on the columns which i want to sum up.
    Any ideas please share with me
    Thanks in advance.

    b) What is the difference between sum and cell sum? Well, I certainly won't claim to be a Discoverer guru. From what little I have seen, the practical result is not any difference really between the two. SUM of a calculated row is adding up the calculation to the total. Whereas cell sum is like adding up the individual values behind the calculation you see. The distinction makes more sense when you have SUM DISTINCT and CELL SUM DISTINCT being involved. Then you will see a difference in the calculated total. But for SUM and CELL SUM itself, I have not seen any difference between the two, but I am still pretty new to Discoverer.
    e) Aggregate field from a folder. Well, this may be one where you have to play around with your own data to understand. Let me try to give you a simple example. Let's say you have a sales table with 100 rows. You have sales data for 5 cities, and each city has 20 rows of sales history. If you pick Sales Dollars Detail and City Name for your workbook and run, you will get 100 rows in your result (complete detail listing). So that is what happens with no aggregation. Now, instead of doing Sales Dollars Detail, you pick Sales Dollars Sum (the same thing as saying SUM(Sales Dollars) in an SQL statement). Run the workbook. You will now get 5 rows of data, instead of 100 rows of data. You will get one row for each city. If you look at the SQL that Discoverer generates, you will see that it has now done a GROUP BY in the SQL statement. Notice I have not said anything about DISTINCT (just trying to keep things simple).
    Now, lets say you do a workbook for City, Part Number, and Sales Dollars Sum. Run the workbook. You get a summarized result (say maybe 10 rows of summary data this time). If you look at the Discoverer SQL, the GROUP BY is now by city and part number, automatically doing that because you picked the SUM version of sales dollars.
    Now lets say you add Sales Units Detail to the workbook. Discoverer will give you a warning message that you are have both an aggregate and a non-aggregate and that you may end up with unpredictable results. Run the workbook. You will be back to 100 rows, because you specified sales units in detail.
    Most of the time I do not want to see detail rows in a workbook. So most of the time I am picking the SUM aggregate for an amount item.
    Hope this explains things a bit. Sounds like maybe you need to take the Discoverer Create Queries and Reports class. Would help you understand these things better. Good luck.
    John Dickey

  • Return only the columns with different values.

    Hi all,
    I am trying to solve a seemingly trivial problem but can't seem to get any straight answer anywhere in any forum. Consider a single table with 5 columns and only two rows:
    row_id           first_name         last_name        age            gender
    1                    John                  doe               27             M
    1                    Jane                  doe               27              F  Assume there is no primary key or any other constraint. Also assume that there are only and only two rows in this table. So I basically need a query that, in the above set of rows, would return first_name and gender, as they are the only differing columns in the two rows, and also their values. Even if i can somehow get the column names that are differing that would be enough as I can easily access the values later on. Also it is important to remember that I may not know the column names of all the columns, so basically I somehow must utilize user_tab_columns in the process.
    Any help appreciated.
    Edited by: 894302 on May 1, 2013 10:35 AM

    Hi,
    894302 wrote:
    There is nothing wrong with it. Here you have added all the columns in the decode statement as you already know all the column names. What if there is a table whose column names are unknown i.e I can pass the table as a parameter to a procedure and I would need to loop through all the columns and then perform this operation.Table- and column names must be hard-coded into the query. If you want to figure out what the columns are at run time, given only hte table name, then you need dynamic SQL.
    All the column names are in the data dictionary view all_tab_columns. You can easily loop through them to build exactly as many lines like
    DECODE (a.row_id,     b.row_id,     NULL, 'row_id,')     ||as you need in the SELECT clause. The FROM clause is dynamic, too: it has the variable table name in 2 places.
    But i am not sure if it worth the effort to do it on the database side. Probably easier to do it on the middle tier such as .NET, which where the business logic is implemented in my company.I don't know much about .NET, so I can't compare them
    It's not very hard to do in PL/SQL (as dynamic SQL goes).
    Edited by: Frank Kulash on May 1, 2013 4:39 PM
    Here's a function that does the dynamic SQL:
    CREATE OR REPLACE FUNCTION  different_columns
    (  in_table_name  IN  VARCHAR2
    ,  in_owner_name  IN  VARCHAR2     DEFAULT USER
    RETURN VARCHAR2
    IS
        return_str     VARCHAR2 (4000);
        sql_str     VARCHAR2 (1000);
    BEGIN
        sql_str := 'SELECT  RTRIM ( ';
        FOR  c  IN ( SELECT    column_name
                          ,        ROW_NUMBER () OVER (ORDER BY  column_id  DESC)  AS r_n
                          FROM        all_tab_columns
               WHERE        owner     = in_owner_name
               AND        table_name     = in_table_name
               ORDER BY  column_id
        LOOP
            sql_str := sql_str || '                DECODE (a.'
                         || c.column_name
                      || ', b.'
                      || c.column_name
                      || ', NULL, '''
                      || c.column_name
                      || ', '')';
         IF  c.r_n > 1
         THEN
             sql_str := sql_str || ' ||';
         END IF;
         sql_str := sql_str || CHR (10);
        END LOOP;
        sql_str := sql_str || '              , '', '''     || CHR (10)
                                || '              )'          || CHR (10)
                     || 'FROM  "' || in_owner_name
                     || '"."' || in_table_name
                     || '" a'                    || CHR (10)
                     || 'JOIN  "' || in_owner_name
                     || '"."' || in_table_name
                     || '" b ON a.ROWID < b.ROWID';
        -- dbms_output.put_line (sql_str);     -- for debugging
        EXECUTE IMMEDIATE   sql_str  INTO  return_str;
        RETURN  return_str;
    END  different_columns;
    SHOW ERRORSYou can call it in SQL like this:
    SELECT     different_columns ('RHIT_TABLE_X')  AS dc
    FROM     dual
    ;Using PL/SQL, we might not need RTRIM, at least not in the query. I'll leave that as an exercise.

  • Return back the stock in a cross company stock transfer environment

    Hi all,
    I have a question in reagrds to Standard SAP Stock transport order with SD and billing (i.e. cross company stock transfer)
    For example:
    Ordering plant (issue Stock transport PO)----
    > Supplying plant (create DO) -
    > Supplying Plant (PGI) -
    > Ordering Plant (GR) -
    > Supplying Plant (billing) -
    > Ordering plant (invoice verification)
    Now my question is...
    if the ordering plant want to return the stock back to the supplying plant due to some business reason, what does ordering and supplying need to do?
    Can the supplying plant now issue a stock transport PO to the ordering plant to buy back (i.e. get back) the stock? is this the right away? and if not what is the right way so that the financial posting can correctly take  place.
    regards
    YY

    Hi Buddy
    Please refer OSS note 430074
    Regards
    Yogesh

  • Small Bug : People detection - O key does not return to the grid view

    Windows 7
    When I hit the O key, I go into the face detection module.
    But when I hit th O key again, I do not come back into the grid view.
    To do so, I have to click on this icon to return to the grid view.

    Grid View is always G key

Maybe you are looking for