MultiColumn sorting of context

Hello Experts,
I need to sort the context nodes, based on 2 attributes of the context, one attr in ascending and the other attr in descending. I referred to the link in wiki http://wiki.sdn.sap.com/wiki/display/Snippets/Tablesorterbymultiplecolumns(WebDynproJava). And as per MultiAttributesNodeComparator.java class given in wiki, I am able to sort the context nodes based on  2 attributes but I can only sort both columns either ascending or descending. I need to sort the context element, with first attribute ascending and second attribute descending. I am using Webdynpro 7.1 .
Replies Awaited...
Regards
Priya

Priya,
Even I am not sure if you can achive this using the table sorter. I would suggest you to take a look at at Vector. It may be able to give you this functionality.
@Srinivas:Business logicwise I don't think both the requirements are mutually exclusive. e.g. there can be a table with two columns, Employee Name and Salary. You may want to sort the Names in ascending order and then is the names of the employees are the same then in descending order for the salary. Just a crude example.
Regards,
Ajay

Similar Messages

  • Sort/order contexts in universe List View Mode

    Is there a way to sort or order contexts in universe List View Mode?
    Thanks

    Hi,
    There is no way to order the contexts in universe list view mode.
    If you want to have a specific order I suggest that you prefix all contexts by a number such as "1 - context name1", "2 - context name2", etc.
    Didier

  • Sort a context node that has subnodes

    I have a context node with cardinatliy 0:1.
    It has one subnode, 3 attributes, and a recursive node.
    Now, I would like to sort the content of the node by one the three attributes.
    How can I do that?

    Hi Daniel,
    but if the subnode is mapped on the parent, it will have the same 0...1 cardinality - and it won't make sense to sort it.
    If perhaps both the parent and subnode have 0...n cardinality but you are only creating one root element - this makes more sense.
    Sorting the second/third/nnn level of a hierarchy is difficult - because it is difficult for the user to specify which level they want to sort. I would assume that you'd just make it so that ALL levels were sorted according to whichever criteria you choose.
    You could consider representing your data as a table popin's (which would then make it more obvious which level was being sorted) but if your data has n levels of hierarchy this will very quickly become a nightmare of recursive dynamic coding.
    As you are no doubt aware, the standard table sorting logic as implemented in CL_WDR_TABLE_METHOD_HNDL does not work for hierarchical tables. (7.01, goodness knows, it might in 7.02)
    So I see two options:
    I think you would either have to go down the path of creating your own table handler, unfortunately the standard table handler CL_WDR_TABLE_METHOD_HNDL is marked as final - so you couldn't just subclass that and override the sort handling (which doesn't work for hierarchical tables). Instead you'd probably have to re-implement. Then reassign the handler in the WDDOMODIFYVIEW. I remember doing similar sorts of things to implement sorting in WDJ in the early days when the standard handler didn't do all I needed it to do. (i.e. it was sorting by key rather than by text for dropdown by keys).
    Or, in the event when you open/display a node, sort the contents according to the state of toggle buttons that you implement in the root node of your hierarchy. When these toggle buttons change state - recursively sort your your entire context.
    This means you don't have to mess with the standard table handler, but does give a very non-standard sort implementation.
    Good luck, if you have any questions, please do let us know.
    Chris

  • How can I sort in Numbers 3.0? All data are getting rolled around!

    I wanted to sort column B
    And that's the result.

    Can't see the what's in the screenshot very well, but here's one way to sort in Numbers 3.0. The menu popped up after I clicked the triangle by D.
    If you're sorting cells with formulas in them, here's a heads up that the sorting behavior has been changed from Numbers 2.3. It now closely matches the sorting behavior of Excel and other spreadsheets.
    If you're trying to sort by more than one column, say first by Name then by RP then by LP, unfortunately Numbers 3.0 does not have that functionality built-in to the interface the way Numbers 2.3 did.  But there's a fairly easy workaround.  Set up a new column E and fill it with the formula =A&C&B, and then just sort by column E.
    Here you seem to have numbers in B and C, in which case if you need a multicolumn sort your formula gets a little more involved because you have to pad the numbers with leading zeros so they sort correctly.  This is easily done with something like this in column E:  =A&RIGHT("00000"&C,4)&RIGHT("00000"&B,4) .
    SG

  • Multi column sorting

    I am wondering if it is possbile to sort data grids in multi
    columns?? For example lets say the data grid simply looks like
    this:
    Name
    Date
    Art 10/29/06
    Chris 12/02/04
    Bob 02/21/07
    Bo 08/08/05
    And i want to sort it in abc order first then within that
    sort(abc order) have does be sorted again by date so that A's will
    stay together, B's and so on...Is this possible and if so how?
    Thanks for all the help

    here is what i have...it crashes after the first click....
    rivate function ctrlCheck(ke:KeyboardEvent):void // checks to
    see if the ctrl key is pressed to do a multicolumn sort.
    if( ke.keyCode == 17) ctrlChecker =true;
    else ctrlChecker = false;
    private function resortColumns(le:ListEvent):void //if there
    is more than one page of results resort the columns and requery,
    else just resort
    colSortedOn = new String("");
    var sortDirection:String = new String("");
    var s:Sort=new Sort();
    var count:int=0;
    var arr:Array=new Array();
    if(le.rowIndex == 0)//get the column sorted on and attach
    that to the query and requery
    if(ctrlChecker==true)
    while(ctrlChecker==true)//while the user is still holding
    the ctrl key
    colSortedOn =
    DataGridColumn(datagrid1.columns[le.columnIndex]).dataField.toString();
    if(DataGridColumn(datagrid1.columns[le.columnIndex]).sortDescending)
    sortLoadDirection = true;
    else
    sortLoadDirection = false;
    arr[count]=new SortField(colSortedOn, true,
    sortLoadDirection)
    count ++;
    for(var i:int =0; i<arr.length; i++)
    s.fields
    =arr
    datagrid1.dataProvider.sort= s;
    datagrid1.dataProvider.refresh();
    else //there is no sort order taking place, the item click
    was something else entirely
    parentDocument.sortCheck = 1;
    }

  • We used to be able to sort by multiple columns/rows at once by right clicking on the header and choosing show more options-how do we do that in the new Numbers?

    We used to be able to sort by multiple columns/rows at once by right clicking on the header and choosing show more options-how do we do that in the new Numbers?  It doesn't appear anywhere.  Do I now have to sort massive tables by each column one at a time now?  Also there used to be an easier way to merge/unmerge cells without me having to go to the table menu each time.  Am I missing something?

    Multiple column sort is a missing feature in the new version.  Hopefully soon to return. You can do a multicolumn sort by sorting one at a time in reverse order of importance.
    For merging and unmerging cells, I select the cells and right click to bring up the contextual menu. Merge and unmerge are on the menu.  You could also create keyboard shortcuts for Merge Cells and Unmerge Cells in the Table menu.

  • When sorting a column of alphanumerical, how do I get them to stay sorted?  When I go to the next column, the first column mixes up.

    How do I get a column of alphanumerical to stay sorted?  When I go to the next column, my first column gets mixed up.

    For my purpose, I'll have to go back to Excel.
    What is your purpose?  Note that Numbers 3.0 does not have a multicolumn sort interface the way you have in Excel (or Numbers 2.3). But it is generally easy to accomplish what you need to do.
    Say you have a column A on which you want an alphanumerical sort and within that you want to sort by B (the equivalent of Excel's "Sort by" A "Then by" B).
    First do a single column sort by B. Then do a single column sort by A.
    SG

  • File Upload Concept Problem

    Hi, I am writing a WAS4 webapp which will allow users to upload files to the WAS machine. I've written and deployed apps on WAS4 before and I create a war file and deploy it via the admin console. But something I don't quite understand is that if I create a folder, say 'upload' underneath my context root such that the path is /contextRoot/upload and this folder is inside the war file, can a user upload into this folder?
    If not, then where must I place the folder in order to perform uploads and how can I reference this folder from my java code? Do I give it absolute machine paths, or some other sort of context relative path?

    Did you try using Jakarta FileUpload? It will answer all your questions.
    http://jakarta.apache.org/commons/fileupload/using.html

  • ITunes 10.6.3 suddenly audio is distorted HELP?

    I am not sure what happened. I am running OSX 10.5.8 and iTunes 10.6.3.
    I have never had a problem before but suddenly the audio is very distroted with some podcasts sound as if they are in very fast motion to the point I can't understand any word spoken.
    The songs are distorted. LIke someone singing into a tin can, and some very low volumn.
    The volume adjustment, as always is at 0.
    I have disabled and then turned on the Equalizer and there is no change.
    Any other audio from my headphones is fine. Final Cut Pro is fine as is my Quicktime movie files.
    PS I have recently had to repair my 30" Cinema display.

    IE and Chrome
    I'd try Firefox ... it handles network connections a little differently from Chrome, IE or Safari, so in cases where there's an issue with IE or Chrome, Firefox can sometimes get a working installer (and vice versa, though IE working when Firefox doesn't in this sort of context is a bit rarer overall than Firefox working when IE doesn't).
    If still no joy with Firefox, I'd try the download of the installer to a different PC.

  • Windows crashes when ipod syncs to itunes&blue screen appears

    Hello and thank you all in advance.
    This all began when I disconnected my ipod because it attempted to delete all of my songs. Long story short, I restored it because it kept saying the ipod was corrupt. when I tried to to connect to connect it to desktop, the ipod wasnt being recognized on itunes but my computer recognized it I think in disk mode or something because the folder showed calender, contacts, etc and was under /f. (This may have been due to itunes needing to be updated.)
    I decide to try on my laptop and I connect the ipod and it is fine until itunes recognizes it and then a blue screen comes up and it restarts.
    It says: "Stop: OX000000023 (OXOOOE100, OXA6ECD548, OXA6ECD244, OX805278AE)"
    When I tried to then use it on my desktop again, it too shut down when itunes recognized it.
    I have no idea what it is but I have a feeling it is due to my laptop because it didn't shut down my desktop until after I tried with my laptop (which I defragmented the night before.)
    Any help will be greatly appreciated!

    It says: "Stop: OX000000023 (OXOOOE100, OXA6ECD548, OXA6ECD244, OX805278AE)"
    that's a fairly rare one in this sort of context.
    is the laptop a Windows 2000 PC? (most of the documentation on that FATFILESYSTEM error at Microsoft refers to Win 2000 boxes.)

  • Why do music videos no longer show up properly?

    After updating to OS5 I notice that music videos no longer show up properly.  
    I have most of mine in playlists, and it show the songs, but only plays the music, not the video?  
    When I view them in 'Videos' I have no option to sort or show them in a different way! 
    Considering the iPad is probably more slanted toward movie content, the lack of features for music videos is very disapointing

    I think this has always been a lacking feature in the iPad videos app but now it is even worse as you can't go into the music app, context navigate to the video you want and play the music video.  It was irritating in the past as it took you back to the lack luster videos app with no sorting or context other than the video tile navigation, now it is TOTALLY un functional.
    APPLE DEVOLPMENT please use the video app with 200+ music videos and see how you like it!  Or does anyone know of a replacement or more advanced app that will allow a better browse and play interface. Apple's is so basic that it is 'still' just painful!
    Music video playlist and shuffle on the iPad would also be nice but sort would be awesome!
    Thanks for any info from anyone on this topic that I have long hopped to be resolved but it is going backward and we are loosing features.
    The new music interface isn't any better in my opinion either, play buttons at the top so your hand has to be over the top of the screen,  store button at the bottom left vs top right as it would be more intuitive like other app purchase button positioning. 
    Anyone know how to make music videos sort better on the iPad (by artist would be awesome)

  • ITunes 10.6.3 won't install, any help?

    I was not able to update iTunes on my computer, running Vista 32 Bit.I followed the instructions to uninstall several programs. But now I can't install iTunes. Any ideas?

    IE and Chrome
    I'd try Firefox ... it handles network connections a little differently from Chrome, IE or Safari, so in cases where there's an issue with IE or Chrome, Firefox can sometimes get a working installer (and vice versa, though IE working when Firefox doesn't in this sort of context is a bit rarer overall than Firefox working when IE doesn't).
    If still no joy with Firefox, I'd try the download of the installer to a different PC.

  • My itune wont open

    hi, i just got my ipod nano and i have had so many problems already. im trying to sort them out but its not working. i installed the cd for the itune+ipod but when i click on the itune it dont open. i uninstall the program so many times and it still was doing the same thing, so i tried and did what the support said and it worked but the song wouldnt play on it and my ipod icon didnt show on my itune. i researched and found some one who had the same problem as me and i tried and did what that person said to do. but now my itune wont open again.. so please any one try and tell me what to do.. i need my itune to open and also play my track and let me put music to my ipod nano. thank you
    hp   Windows XP Pro  

    it said the same think
    Ahhh. "QuickTime Player has encountered a problem" is one of the possible messages in this sort of context.
    So let's first try swapping out your QuickTime.
    Head into your Add/Remove programs. uninstall QuickTime.
    Next, we’ll manually remove any leftover program files and folders.
    1. On the Start menu, click My Computer (or double-click My Computer on the Desktop).
    2. In My Computer, open Local Disk.
    3. Open Program Files.
    4. Right-click on the QuickTime folder and click Delete from the shortcut menu.
    5. Navigate to C:\Windows\system32\.
    6. Remove the files QuickTime.qts and QuicktimeVR.qtx. (If “Hide filename extensions for known file types” is enabled on the PC, then those two files will appear as “QuickTime” and QuickTimeVR”.)
    7. Restart your computer.
    Next, we'll get a fresh copy of QuickTime into your PC by doing a repair install of itunes.
    Switch off antivirus and antispyware applications prior to the repair install.
    Go into Add/Remove and select itunes. Click "Change" and then click "Repair".
    If the repair install goes through okay, restart the PC and try launching itunes again. Does it launch properly now?
    (If you get an error message on the QuickTime uninstall or the iTunes repair install, let us know what it says.)

  • How to index a gzipped pdf blob

    Hi,
    I already have a TAR logged on this but if anyone knows how to do this, I would greatly appreciate any tips.
    I have our PDF documents stored in BLOB's in our DB but they are stored in gzipped format for significant space savings. I have developed two oracle functions; "gzip" and "gunzip", which are wrappers to java classes loaded into the DB, that can do the gzip compression and uncompression on the fly. These functions
    accept BLOB's and return BLOB's. I use these functions to send the documents to client browsers, etc.
    Now, I want to index these PDF documents but have hit problems.
    Eg, suppose the table structure is; STREAM(STREAM_ID NUMBER, PDF_GZIPPED BLOB). I need to build an Oracle Text index on
    STREAM(unzip(PDF_GZIPPED)). Where the unzip function accepts a BLOB and returns a BLOB (the real PDF document).
    My original approach was to use the multicolumn datastore because context indexes using these datastores could be based on functions of the table columns rather than just table columns. Oracle support informed me that multicolumn datastores will only work for VARCHAR2 types (not BLOB's) so I can't use that.
    If anyone has experience in indexing table/column functions for BLOB's, I would be interested to hear how to go about it. Please remember our PDF BLOB's are gzipped, not just PDF documents dumped into BLOB's.
    Harris.

    Sorry, the "unzip" function should read "gunzip" in the previous post.
    Anyway, for those interested, I have found a temporary workaround but boy is it cludgy;
    1. Had to setup a USER_FILTER
    2. Wrote a shell script wrapper to ctxhx
    3. But ctxhx on 8.1.7.2 always failed (unsure at this stage)
    4. So, it calls ctxhx under a previous version of Oracle;
    Here is the code;
    exec ctx_ddl.drop_preference('unzip_filter');
    exec ctx_ddl.create_preference('unzip_filter','USER_FILTER');
    exec ctx_ddl.set_attribute('unzip_filter', 'COMMAND', 'unzip_inso');
    exec ctx_ddl.drop_preference('pdf_lexer');
    exec ctx_ddl.create_preference('pdf_lexer', 'BASIC_LEXER');
    exec ctx_ddl.set_attribute('pdf_lexer', 'printjoins', '_-');
    drop index cas_stream_blob_ctx_i;
    create index cas_stream_blob_ctx_i
    on cas.stream_blob(pdf_gzipped)
    indextype is ctxsys.context
    parameters('filter UNZIP_FILTER lexer PDF_LEXER');
    exec ctx_ddl.sync_index('cas_stream_blob_ctx_i');
    Here is the source of unzip_inso;
    #!/bin/ksh
    test $# -lt 2 && return
    TMP_DIR=/tmp
    TMP_FILE=${TMP_DIR}/ora_gunzip_$$
    /usr/bin/gunzip -cf $1 > ${TMP_FILE} &&
    OUTFILE=$2
    shift 2
    #$ORACLE_HOME/ctx/bin/ctxhx ${TMP_FILE} ${OUTFILE} $*
    # 8.1.6 workaround
    export ORACLE_HOME=/product/oracle/8.1.6
    export LD_LIBRARY_PATH=$ORACLE_HOME/ctx/lib:$LD_LIBRARY_PATH
    export LD_LIBRARY_PATH_64=$ORACLE_HOME/ctx/lib64:$LD_LIBRARY_PATH_64
    ${ORACLE_HOME}/ctx/bin/ctxhx ${TMP_FILE} ${OUTFILE} $*
    rm -f ${TMP_FILE}
    It works - but very ugly.
    Still seeking a better solution - since I have the gzip utilities
    already loaded in the DB.

  • Unable to load itunes

    I use my itunes frequently, but went to use yesterday and got the following message - windows cannot access the specified device, path, or file. You may not have the appropriate permissions to access the item - in desperation I deleted itunes and attempted to re-install but receive the same message.

    No unfortunately not. I typed out exactly what it said.  We could be searching for a needle in a haystack?
    Not quite ... the way it's happening when you try to reinstall as well as launch indicates it's a Windows Installer error. (They can be triggered by launches as well as installs because iTunes uses "advertised" shortcuts that call on Windows Installer to do a check against the Windows Installer database for iTunes to make sure all the files/registry-keys/whatnot that should be on the PC are still there. If they aren't, Windows Installer will run a repair install of iTunes ... in this case the trouble affecting reinstalls is also borking the repair install.)
    Although it's not a familiar Installer error in this sort of context, there's a couple of major classes of installer errors which tend to crop up in this context ... so at least we've got a bit of a handle on which two parts of the haystack we should check first ...
    I think we should check on disk/file damage first. (If a program file or folder is damaged enough, that can muck up an install or repair install like this.)
    The first thing I'd try with that is running a disk check (chkdsk) over your C drive (or whichever drive your itunes program files are installed on). There's XP instructions in the following document:
    How to perform disk error checking in Windows XP
    Select both Automatically fix file system errors and Scan for and attempt recovery of bad sectors, or use chkdsk /r (depending on which way you decide to go about doing this). You'll almost certainly have to schedule the chkdsk to run on startup. The scan should take quite a while ... if it quits after a few minutes or seconds, something's interfering with the scan.
    Does the chkdsk find/repair any damage? If so, try launching iTunes again. Does a repair install go through successfully now? If so, do we get an iTunes launch after that?

Maybe you are looking for