Issue in sorting

Hi all,
I want to display records from an internal table with similar description together.
I have an internal table with few fields and one among them is description.
I want to display records with same description.I can sort on description but because my descrption contains alphabets numericals etc its giving me a dump error.
for ex descriptions looks like thise
ILETIN II PK REG 100  1 X 1
PHENERGAN DM 120ML  1 X 1
SOLU-CORT 500MG 4ML  1 X 1
PROTAMINE SULF 250mg 25ml 1x1 Lilly
TIMOLOL OPHTH XE 0.5%SOL 1x1      MSD
all i want is same  descriptions  should display together.
You can say that you can sort on material number but the problem is for different material number there is possibility of having same description so i cannot sort on material number to achieve this .
Please send me your thoughts on this one.
Thanks in advance

Hi,
Did you try this option : <b>SORT <itab> ... AS TEXT ... .
</b>
Give the dump info it will help to analyze the problem .
Thanks,
Varun .

Similar Messages

  • Issue with Sorting by Custom Attributes

    In our custom SES query application, I am trying to implement sorting at the custom attribute level. I am having difficulty in understanding exactly how to set the options on doOracleOrganizedSearch() to achieve the desired result.
    We have a table based content source and allow a user to search via custom search attribute. We are also going to allow them to sort by custom attribute.
    For example, say we have a Project content source and one of the attributes is "Client Name". Users are going to be able to sort by client name (A-Z and Z-A). I have a prototype working but it only seems to work if I set topN to a very high number.
    I want to bring back the first 10 documents sorted by Client Name A - Z and allowing paging to the next set of sorted results. My prototype works if I set topN to 1000 (more than the # of results) but does not work if I set it to 10 (# of results I want to display per page).
    Below if my code. Note I am not setting the group attribute or the cluster list. Perhaps this is the issue?
    Many thanks in advance!
    OracleResultContainer results = service.doOracleOrganizedSearch
    (this.m_query, // query
    this.m_docsRequested, // topN
    this.m_startIndex, // startIndex
    new Integer(10), // docsRequested
    this.m_dupRemoved, // dupRemoved
    this.m_dupMarked, // dupMarked
    this.m_searchDataGroup, // groups
    this.m_queryLang, // queryLang
    this.m_docLang, // docLang
    this.m_returnCount, // returnCount
    this.m_filterConnector, // filterConnector
    filters, // filters
    this.m_fetchAttributeNames, // fetchAttributeNames
    null, // searchControls
    null, // groupAttr
    this.m_sortAttributes, // sortAttrList
    null); // clusterList

    Hi Nikola,
    in 9.0.1 even if you rewrite the web interface you can't sort files by custom attributes setting a SortSpecification to a Folder. You can only sort by base attributes with getItems(). To get item sorted on custom attributes you must perform a search (a lot more codelines).
    Regards, Alessandro

  • Issue with sorting of TO line item while using LM05 / LM07

    Hi,
    We have found an issue in using LM05 / LM07 trnasactionwhile performing picking activity using the RF transaction.
    1. Transfer Order is created for the same Material and Batch Combination with multiple line items. So when we display the TO the materials appear in the sequence of TO line item say 1, 2, 3, 4, 5 etc.
    2.  When we try to confirm the transfer order using LM05 the system is not picking the line items in the order that the TO was created. It is pickinga a random line item from the order and selecting an item from the lower line items of the TO's.
    We have debugged and found that there is no specific sort sequence which is changing the sequence of line items as all the sort eliments have the same values except that there are few empty fields. The statement where the sort sequence is changing is 'SORT TMP_SORT_TAB BY NLTYP SORLP NLENR MATNR CHARG' but my concern is it is not sorting by this sequence specified in the code after execution.
    If anyone has seen this kind of an issue and has a solution please let me know.
    Thanks in Advance,
    Harish

    As for std SAP ME59N - make sure there is not rounding value is activated in the Material master as well as info record
    If this is not the case than check any custom code is activated for ME59N
    becuase generally in many compnay when they use ME59n they don't want the same material from diff PR to create the diff line item in the PO so using the custom logic in the user exist they trick the code
    it might be the case for you where you have issue.

  • Print Issue with Sorted ALV Grid

    Hi Team,
    I am using ALV display for my Program. Iam using REUSE_ALV_GRID_DISPLAY. Also i have a Sorting condition for my ALV grid. So iam filling the Sort table & passing it to the Function module. The data is displayed correctly with Sorting as required in the Output.
    Now the issue is with: Print from this ALV. When we try to print the data, The requirement is that the Print should be same as how it is displayed in the ALV. "Grouped Columns"..... But now, the Print is that all the data is filled in all the columns. But user wants the Print also to appear  same as it is shown in a Sorted ALV display.(With some similar column data missing in succeding sort columns until new entry starts)
    Please suggest a solution to acheive the same.
    Thanks & regards,
    Chaitanya

    Look at Q#19 in the note 1009650. Merging functionality is available only for ALV grid display.
    Related Note: 447055
    Work around would be to display the excel in the SAP window (Excel in Place)  and print it from Excel. Read the following thread to make the necessary settings to make it work. Download Report exactly same as seems with Layout set !!
    Edited by: Jeevan Sagar on Jan 19, 2012 12:38 AM

  • Multiple selection causing issue when sorted

    I have an issue when using multiple selection along with sortable column. If certain rows are selected and then a column is sorted, selected rows remains as it is but data changes. Moreover sorting happens within the rows in the page and not across the table. Please provide me solution. Thank you
    <af:table value="#{bindings.CntTypecntItem.collectionModel}"
    var="row"
    rows="#{bindings.CntTypecntItem.rangeSize}"
    first="#{bindings.CntTypecntItem.rangeStart}"
    emptyText="#{bindings.CntTypecntItem.viewable ? 'No rows yet.' : 'Access Denied.'}"
    width="860" id="tblSearchIcLcResults"
    binding="#{SearchNAssign.tblSearchIcLcResults}">
    <f:facet name="selection">
    <af:tableSelectMany required="false"/>
    </f:facet>
    <af:column sortProperty="ctry"
    sortable="true"
    headerText="Country">
    <af:outputText value="#{bindings.countryName.inputValue}"/>
    </af:column>

    Hi,
    if you are on a POJO business service, make sure the primary key attribute is set for the PK attribute in the generated data control XML file. So if your entity is "Employees" then select "Employees.xml", open the Structure Window (ctrl-shift-s) and select the attribute that is the PK. In the property inspector,set he PrimaryKey property to true
    Frank

  • Issue in sorting table column

    Hi,
    I am using Oracle Jdeveloper 11.1.1.6.2
    I am trying to apply sort functionality to a acolumn in my table. I have done this previously at many places and it worked fine, But over here we are having a switcher inside column the code is:
           <af:column sortProperty="KeywordName"
                         headerText="#{coregccomplianceuiBundle.KEYWORD_NAME}"
                         id="c1" rowHeader="unstyled" sortable="true">
                <af:switcher id="sw1" facetName="#{row.IsSystem}" defaultFacet="0">
                   <f:facet name="1">
                   <af:panelGroupLayout id="pg1" layout="horizontal">
                      <af:outputText value="#{row.KeywordName}" id="ot1"/>
                      <af:image source="/images/lock_ena.png" id="cil1"
                                shortDesc="#{coregccomplianceuiBundle.ERRMSG_ISSYSTEMENTITY_DELETE}"/>
                    </af:panelGroupLayout>
                  </f:facet>
                  <f:facet name="0">
                  <af:panelGroupLayout id="pg1-1" layout="horizontal">
                      <af:outputText value="#{row.KeywordName}" id="ot1-1"/>
                    </af:panelGroupLayout>
                  </f:facet>
                </af:switcher>
              </af:column>initially i have all the columns which come under facet 1 , i try to sort it works fine. Then i add a row of facet type 0 and then if i try to sort it does only sort the rows with facet =1.
    What can be the issue?
    Thanks,
    Tripuresh
    Edited by: Tripuresh on May 29, 2013 5:23 PM

    Thanks Prateek and Shah for the reply,
    Actually i can see now that even if i remove the switcher component completely and make the column like:
             <af:column sortProperty="KeywordName"
                         headerText="#{coregccomplianceuiBundle.KEYWORD_NAME}"
                         id="c1" rowHeader="unstyled" sortable="true">
                      <af:outputText value="#{row.KeywordName}" id="ot1"/>
              </af:column>Then also for the newly added rows sort is not working. The addition of new keyword is done by logic below:
            ComplianceLibraryAMImpl am = getDataControl();
            EmKeywordVOImpl rep = am.getEmKeywordVO1();
            NameValuePairs nvp = new NameValuePairs();
            nvp.setAttribute("KeywordName", keyword);       
            Row row1 = rep.createAndInitRow(nvp);
            rep.insertRow(row1);is there something wrong in my addition logic?

  • Aperture 3.2.1 still issues with sorting images in albums, after making adjustments, cannot use arrow keys to go to next image. straightening tool auto turns image prior to straightening inconsistantly

    Have updated aperture to 3.2.1, still having some issues during editing images.
    1. Basic item is sorting images does not happen correctly, move some images in file, they don't move correctly, after trying to move several, then they almost randomly move around.
    2. Straightening tool will automatically tilt images as soon as you touch the tool, turns them on about a 30 degree angle clockwise.
    3. Arrows on right side of keyboard used to move images in browser from the editing position, they move them if no editing is done, once you edit an image, cannot move to the next image using the arrow keys.
    tks, gmoney in ladner

    Oh, baby! This bad boy flies!! Here's what to expect:
    I had 40,000 images in Aperture 3 and it was dog slow at everything. I installed 3.1 update today. It took 5 minutes to update the database and then behaved marginally better than before at ASIC library navigation. I was disappointed.
    Then I QUIT the app. It took a couple of hours to "update files for sharing" with a counter that went to 110,000 images. So it must have updated every thumbnail and variation of preview. Turned it back on , and BAM. Came up fully in seconds. Paused for 10 seconds ten everything was lickrty split. For the first time ever, I can use the Projects view with all 791 projects and scroll quickly. I even put it in photos modevand whipped thru all 49,000 images!
    Haven't done anybprocessing yet, but i'm liking it!!
    Jim

  • Issue with sorting in a PPR report

    Hi:
    I have a report based on a query that references a view whose defining query references a remote table. I have the columns of this report enabled for sorting and there is no default sort column specified
    All is fine when the page containing this report is called up for the first time. The problems start once I click a column heading to sort the report by that column. The report then renders with fewer than 15 rows (the rows per page value) and hence the pagination links disappear. if I now click a different column heading then more than 15 rows are shown again. I cant say whether the truncation of the result set ihappens only when sorting by a particular column. It does appear to be random. Surprisingly, if PPR is disabled then this bizzare behaviour is not seen.
    Any idea what is going on here ?
    Varad

    Hi Carl:
    I have posted the page at apex.oracle.com. The URL is http://apex.oracle.com/pls/otn/f?p=23548:22
    However, the problem doesnt manifiest itself here.
    Further investigation on my side leads me to believe that it is the contents of one of the columns displayed by the report (column named STMT) that appears to be the culprit. I remove this column from the report and all is well. The column contents are pl-sql/SQL statements. I cant understand why the contents of the column should matter.
    Thanks for your response.
    Varad

  • Issue with sorting results on the basis of specfic values.

    Hello,
    I written an sql that will sort the results on the basis of values defined in 'IN' clause. I have made use of CASE statement in ORDER BY clause. Its not functioning. My code is:
    SELECT GWLO.productcode,
              GWLA.parentsampletype,
              GWLO.sampletype SampleType,
              max(GWLA.loginid) Loginid,
              max(GWLA.modifiedts) modifiedts
         FROM gwloginattribvars GWL,
              gwloginkeyvals GWLO,
              gwloginkeysadmin GWLA
         WHERE GWLO.productcode = GWLA.productcode
              AND GWLO.sampletype = GWLA.sampletype
              AND GWLO.productcode in ('1002124', 'ABPG', 'ABIG')
              AND GWLO.sampletype <> 'CERTIFICATE-OF-ANALYSIS'
              AND GWLA.parentsampletype IS NOT NULL
         GROUP BY GWLO.productcode, GWLA.parentsampletype, GWLO.sampletype
         ORDER BY
              (CASE GWLO.productcode WHEN '1002124'     THEN 1
                   WHEN 'ABPG'     THEN 2
                   WHEN 'ABIG'     THEN 3
                   ELSE 'LL'
                   END) ASC
    I expected the results to be in sequence what it is defined in CASE - ORDER By clause. This code is givin me error. The error is
    (CASE GWLO.productcode WHEN '1002124' THEN 1
    ERROR at line 16:
    ORA-00907: missing right parenthesis
    Please help. Thanks!

         ORDER BY
              (CASE GWLO.productcode WHEN '1002124'     THEN 1
                   WHEN 'ABPG'     THEN 2
                   WHEN 'ABIG'     THEN 3
                   ELSE 'LL'>                END) ASC
    Can u just explain me in this context? I think it should be another number in the else part - since you are returning numbers in all the 'WHEN' option. Pls explain it.
    Regards.
    Satyaki De.

  • Issue on sorting the legend

    Hi guru's
    Im trying to sort the legend for vertical stacked chart and seems it doesn't work.
    The color order on the vertical stacked bars are oppositely shown , when compared to legend.
    For example : If a legend shows green on top of the legend(1st) the green appers at the bottom in vertical chart. 
    Thanks in advance..

    Check this post
    Bar-Line chart sorting
    If helps pls mark also update with your solution that helps other :)

  • Issues with sorting in Finder

    I recently downloaded about thirty documents into my "Downloads" folder. I was hoping I might be able to move these documents en masse to another folder. Unfortunately, Finder wouldn't let me sort the folder by the time I first received the files. If I sorted by "Date Created", it didn't work, because these thirty documents were all created at different points throughout the semester and thus they were spread all throughout my "Downloads" folder. It was a real pain trying to find everything I just downloaded for purposes of putting them into a separate folder. Am I missing something here, or is Finder just not capable of doing this for some reason?

    This doesn't help, unfortunately. These files were last modified on different dates across the past few months. Downloading them onto my computer doesn't change the modification date.

  • Issue on sorting the fields in ALV Grid

    I have created a report in ALV Grid I have sorted the fields using slis_sortinfo_alv to avoid the duplicates . I could display the output in sorted fashion, but when I export it to a file it is displaying in the same fashion as it is in the database that is in the allowing duplicates.. I cant use DELETE ADJACENT DUPLICATES as it will delete the adjacent records . i need help from you guys please help me...

    Hi,
    As you have data in your internal table that is to be displayed in the alv grid display.
    So, instead you can sort the internal table on that field and then can delete the duplicate records comparing that very field.
    Use code:-
    sort <itab> by <field_name>. "to sort
    delete adjacent duplicates from <itab> comparing <field_name>. "to delete duplicate entries
    This will delete all the duplicates records for the column.
    Now you can use this internal table to display the data in the ALV grid.
    Or if you dont wish to delete the data from the initial internal table, then you can use a temporary internal table of same structure and use:-
    it_temp = itab.
    sort it_temp by <field_name>. "to sort
    delete adjacent duplicates from it_temp comparing <field_name>. "to delete duplicate entries
    Now you can use this internal table to be displayed as alv output.
    Hope this helps you.
    Thanks & Regards,
    Tarun

  • Issue Tracker (sorting help

    Hi team, is there a way to  have the updates being sorted by dates.

    thanks for ur prompt response.
    In se09, there is one change req and it has two child requests and all these are not released.
    change req:
    first child req has,
    customer enhancement projects: ZENH
    second child req has components:
    table definitions: zdtfiar_3,
                           zmc03um0
    customer enhancement projects: ZENH
    program: zxrsau01,
                  zxrsau02
    table :  zdtfiar_3,
               zmc03um0
    I need ur suggestion here.
    while creating project, it is prompting for req. Can i create new request or just delete above objects from se09 first & choose same request(main)? Any suggestion pls.
    waiting for reply..thanks.
    V N

  • Issue in sorting data in already existing abap code

    Hi all,
    I have a code which fetches the data into an internal table. The content of the internal table is as follows(example):
    1) Header 1 amount 1
    2) item1 amount 2
    3) item1 amount 3
    4) item1 amount 4
    5) header 1 amount 5
    6) item2 amount 6
    7) item2 amount 6
    8) item2 amount 6
    9) item2 amount 6
    10)header1 amount 7
    Now i need to modify the code in such a way that the output should add up all the amounts of the header and a line items and should be displayed at the end of the line items as follows.
    1) item1 amount 2
    2) item1 amount 3
    3) item1 amount 4
    4) item2 amount 6
    5) item2 amount 6
    6) item2 amount 6
    7) item2 amount 6
    8)header1 total amount
    I tried using collect statement, but the header is being displayed at line1 and not line 8 where needed.
    Please do help me and let me know how best can i modify my code.
    In case you are wondering what my req is , it is based on the OB58 configuration.

    HI,
    u have told this scenario -->
    1) Header 1 amount 1
    2) item1 amount 2
    3) item1 amount 3
    4) item1 amount 4
    5) header 1 amount 5
    6) item2 amount 6
    7) item2 amount 6
    8) item2 amount 6
    9) item2 amount 6
    10)header1 amount 7
    I iam not wrong then i think u want the o/p in this way
    1) item1 amount 9
    2) item2 amount 24
    3)header1 amount 13
    But one doubt can there be scenario in this way to if am not wrong
    1) Header 1 amount 1
    2) item1 amount 2
    3) item1 amount 3
    4) item1 amount 4
    5) header 1 amount 5
    6) item2 amount 6
    7) item2 amount 6
    8) item2 amount 6
    9) item2 amount 6
    10)header1 amount 7
    11) header 2 amount 5
    12) item2 amount 6
    13) item2 amount 6
    14) item2 amount 6
    15) item2 amount 6
    16)header2 amount 7
    Regards,
    Madhukar Shetty

  • Urgent please-sorting code issue in BIP

    Hi,
    issue with sort order in BIP reports. I gave code like this but saying expression error. Please help me.
    sort should be in the order of numbers , then upper case then lower case values.
    declared variable is <?variable: srtStr; "'01234567890ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz'"?>
    then i am trying to apply code in my group
    <?for-each-group:ssAssetMgmtAsset;./ssReferenceNumber3?><?sort:current-group()/string-length(substring-before ($srtStr,substring(ssReferenceNumber3,1,1)));'ascending';data-type='text'?>
    the above code saying expression error
    Thanks,
    lax

    What is the exact error you get?
    I believe that the data-type (within the for-each-group) should be number. Try that and let me know if that fixes your issue.
    Thanks,
    Bipuser

Maybe you are looking for