Urgent!  Details of english sort orders in SQL databases

I need (for reasons that would take too long to explain and probably breach company security) to duplicate in Java (preferably a Comparator) the sorting order used by a SQL database.
I can find lots of things telling me how to tell a database to use a sort order, but nothing will tell me exactly what that order is.
Does anybody have a clue? And yes, we are prepared to buy books for this.

It is probably different for each database. It can even be different for different installations of the same database if the charset can be custom set. You would need to know the specifics for the database you are working with, which the dba should know.

Similar Messages

  • Urgent: English sort orders

    (yes, i posted this in another group as well. i'm desperate, ok?)
    I have SQL database in which one table is sorted using english sorting (EN_US, EN_UK, whatever) rather than dumb ASCII sorting.
    For reasons that would take far too long to explain, i need to duplicate that sort procedure in a Java Comparator.
    Can anybody point me to exact details of the comparison rules used by the database?

    Without knowing what the database is, no. If the documentation for your database doesn't have an appendix explaining its sorting sequence, maybe it has an associated website that does. (To tell the truth, I couldn't tell you even if you did say what database you were using. But the answer is still in the database, there's no standardization for that sort of thing.)

  • Bug - Sorting Order in SQL Reports not Working?

    Today i defined a SQL Report in APEX and choose 3 columns for sorting the report.
    The order is like that:
    1. Category
    2. List Price
    3. Product Name
    When calling the SQL Report in a new session i expected to get a sorted report like defined.
    I got only the report like the last person who edited this report.
    It looks like that the Sort Sequence columns is not usable in SQL Reports.
    Here is an example based on the problems which i described:
    http://apex.oracle.com/pls/apex/f?p=40082
    below the SQL Report a screenshot is shown, where the Report Attributes (and the sort sequence) is displayed.

    OliverL
    Did you reset the pagination of the report you made the changes to?
    Normal behaviour is that APEX remembers per user per report the last sorting that was used.
    Including when a user clicked a column header to change the order from the default one.
    The sort preference are stored in preferences with a name like FSPapp_id_Ppage_id_Rinternal region_id_SORT.
    Nicolette

  • Sort order of Imessages and SMS

    In previous IOS versions, when you deleted a Imessage or an SMS, the sort order of message automatically changed to last date. In IOS 8.1 the sort order
    doesn´t do this, which means that if you delete a message send today and the one before that was sent yesterday, the message is not moved "down" my list and counted as from yesterday it still stays as if it was sent today.
    Could you please fix this.
    Thx (Apple 6 User)

    The issue isn't really the T in The Beach Boys. The issue is the inconsistency between the sort in Finder, the playlist sort in the side bar, and the sort within Music.
    1) If you make a smart playlist The Beach Boys, it will be sorted in the side bar under T, not under B.
    2) If you make a smart playlist 409 (containing The Beach Boys' song 409), it will be sorted at the top before the letter A. In Music, it will be at the bottom, after the letter Z.
    While this behavior may be of long standing, it is still inconsistent. I think we should be given an option as to how we want to sort numbers and punctuation marks. I assume that the american english sort order is not imposed on other language versions of iTunes. It shouldn't be difficult to allow the sort to match the locale of the computer, so that iTunes sorts match Finder sorts.
    P.S. Most of my files are wave files from old records and tapes. I chose to name The Beach Boys The Beach Boys and The Beatles Beatles, i.e., I chose to put one under T and one under B. Only The Band, The Beach Boys, The Who, and The Soul Stirrers were worthy of the extra The, to be sorted under the T's where I wanted them to be (sorry Beatles).

  • Sorting Order - Urgent Help.....

    Hi all,
    I am doing migration from SQL Server 2K to Oracle 9.2.0.5.0.
    I need to compare data from Oracle and SQL Server.
    What is the default sorting behavior for Oracle? I mean I have a select statement like -
         Select <column> from <table>
    This table doesn’t have a primary key. It doesn’t have an index also. It has two columns – col1 is NUMBER and col2 is VARCHAR2 (50). When I retrieve data from Oracle it is sorting according to ROWID. As per my understanding ROWID is in the same order in which data was loaded in the table. In one case, I have found that ROWID is different from the data load order. My requirement is to order both Oracle data and SQL Server data so that I can compare them row by row. In absence of a key and an index what is the parameter based on which oracle sorts the data for a table?
    I have NLS_SORT=BINARY and NLS_LANG=BINARY.
    The result of a query 'select * from table1':
    col1 col2
    3 Unknown
    3 CAN-seeking
    3 Preclinical
    3 Phase I
    3 Phase II A
    3 Phase II B
    3 Phase III
    3 Registration
    3 Phase IV
    4 Discovery
    4 Unknown
    4 CAN-seeking
    4 Preclinical
    4 Phase I
    4 Phase II A
    4 Phase II B
    4 Phase III
    4 Registration
    1 Phase IV
    4 Phase IV
    5 Discovery
    The result of 'Select * from table1 order by col1':
    col1 col2
    3 Unknown
    3 CAN-seeking
    3 Preclinical
    3 Phase I
    3 Phase II A
    3 Phase II B
    3 Phase III
    3 Registration
    3 Phase IV
    4 Discovery
    4 Unknown
    4 CAN-seeking
    4 Preclinical
    4 Phase I
    4 Phase II A
    4 Phase IV
    4 Phase II B
    4 Phase III
    4 Registration
    5 Discovery
    Can anybody help me on this....
    Thanks in advance.....

    Doesn't Oracle sort by ROWID by default? What is the order in which it fetches the results from the result set? I am really lost at this..... I have used this logic:
    Sort by primary key, if it exists
    Sort by first NUMBER column in absence of primary key.
    However, the order from SQL Server and Oracle when sorted on col1 as in my explanation is different.
    SQL Server uses SQL_Latin1_General_CP1_CI_AS. The SQL Server result for -
    'select * from table1 order by col2' is:
    col1 col2
    3     Unknown
    3     CAN-seeking
    3     Preclinical
    3     Phase I
    3     Phase II A
    3     Phase II B
    3     Phase III
    3     Registration
    3     Phase IV
    4     Discovery
    4     Unknown
    4     CAN-seeking
    4     Preclinical
    4     Phase I
    4     Phase II A
    4     Phase II B
    4     Phase III
    4     Registration
    4     Phase IV
    5     Discovery
    Thanks

  • Sort Order in detail Tiles CRM3.0 MSA

    Hi there,
    I've got a small question about the sortordering in the detail tiles. I tried to change the sort order but I'm not able to find the sourcecode where I can change this. I just had a look at the tile, the querry and the Bdoc.
    It would be very great if somebody could help me.
    Best regards
    Christian

    Hi Stefan,
    since this tile is a list tile (not a detail one) you can also use an alternate solution for your problem. Just put the following VBA Code in e.g. the onload event of your tile for the underlying grid:
    [Name of Gridcontrol].sortCol = X
    where X is the columnnumber of the list after which should be sorted. Positive Numbers for Ascending Sorting, negative Numbers for Descending Sorting. (Could be vice versa )
    Regards, Marco

  • Russian and English combined Index Group Title and sort order

    How should I create the combined index Group Title and sort order in Russian and Greek documentations?

    The final product one Russian manual which contains some English Index marker ...
    And what is the problem?
    You can control the sorting by placing a [...] tag in the Marker Text, such as:
    [Сплайн] Spline
    The term(s) in the brackets are used only for sort. What appears in the Index is the following text.
    Or you can just edit the Marker Text.
    But it sounds like there might be more than one question here, re: Group Titles.

  • Sort order of german characters in SQL statements

    I've a problem concerning the sort order of the german characters 'd'. 'v'. '|' in SQL statements.
    Environment : Oracle Server 7.3.4
    SINIX 5.43
    The statement comes from an Windows application over OCI to the database.
    The result of setting the NLS_SORT param to 'German' is that these characters are treated the same as 'a', 'e' and 'u', and not like 'ae', 'oe' and 'ue', as it is expected.
    e.g. ascending sort order :
    Bube, Bulut, B|schgens, Butza
    but expected is: (| = ue)
    Bube, B|schgens, Bulut, Butza
    Any idea ?
    Thanks for any help in advance.

    If two single quotes don't work, try backslash single quote, like \'
    The backslash is often used as an escape character, meaning to treat the next character literally.
    - tbob
    Inventor of the WORM Global

  • 30EA2 - SQL-Developer 3.0.02 Another Table Data Sort Order Bug

    Although the "30EA1 - SQL-Developer 3.0.02 Table Data Sort Order Bug" still exists in 30EA2, there is a new substantial mistake.
    How to see it:
    Open table1 (Preference "Automatically Freeze Object Viewer Windows" is set). Click data.
    Open table2. Click data.
    Go back to table1. Click Sort. => You see the columns of table2. The is no way to sort table1, before you close the table2 window (tab).
    Edited by: oestreicher1 on 01.12.2010 04:54

    Logged Bug 10358797 - ea2: grid sorter shows wrong columns
    -Raghu

  • Sort Order Column not Working

    I have set a sort order column on one of A VARCHAR field, but the functionality is not working. The sorting is enabled in the table view and when I sort by the said column it still sorts based on the VARCHAR values of the column instead of the other INT column I want to sort by. The logical SQL and physical query never even includes the column to sort. Are there any exceptions for the 'Sort Order Column' setting? Is there a config setting or data connections setting that I need to check to make this work?
    Thank You!
    Edited by: VNC on Oct 3, 2011 9:08 AM

    hi,
    can you give me more detailes like some sample column data like below kind
    Like Ex: varchar month column it sould display based on month id
    month : Fev-2011,Dec-2011,jan-2011 and month id 1 to 12
    set your month id as sort order column of month name.
    double click month name ->In general tab set the sort order column as month id
    FYI...see the sample link
    http://www.biconsultinggroup.com/obiee-tips-and-tricks/setting-a-sort-order-column.html
    i hope helped you
    THanks
    Deva
    Edited by: Devarasu on Oct 4, 2011 12:39 AM

  • Changing sort order in Finder to display folder first

    In almost every other release of OS X there was a tweak to edit the frameworks so that you could have finder, when sorting by "Kind/Type"you could display folders first. Well of course they broke that in Leopard.
    Has anyone discovered a way to reinstate this nice little feature so that folders don't appear at the bottom of the list view but at the TOP like PathFinder?
    For those that are curious here WAS the "tweak" (go to System: Library: Frameworks: ApplicationServices.framework: Versions: A: Frameworks: LaunchServices.framework: Versions: A: Resources. Whew. Within that folder, you’ll see the English.lproj folder. Highlight it, and then select File: Get Info. In the Ownership & Permissions area, click on the Details triangle, click on the lock icon, and then click on the Owner pop-up menu and set it to your user name (enter your password if asked). Leave this window open; you’ll be changing it back in just a minute.
    Inside the English.lproj folder is a file named Localized.strings. Drag it onto TextEdit. Find the line that reads "Folder" = "Folder"; and insert a space before the F in the second Folder.)
    TIA,
    Peter

    Hi VFRJOEY,
    there is no way to change the sort order in column-view. This was under discussion since the very first release of MacOS X but never made it into any one of the releases.
    If this answered your question please consider granting some stars: Why reward points?

  • List of found events changes sort order when pasted from clipboard

    when I find a set of events in iCal, the list appears in the window at the bottom of the page in the correct sort order when sorted by date, title or type. When I then copy that list to the clipboard and paste it into another program (Pages, MacJournal, TextEdit) the sort order changes.
    I work mostly in English, but my macbookpro keyboard is German, so I assume the problem is with the language settings. I've tried changing the system preferences for language and sort order, and that changes the sort order, but it doesn't get it right.
    Anyone have any ideas?
    Thanks

    when I find a set of events in iCal, the list appears in the window at the bottom of the page in the correct sort order when sorted by date, title or type. When I then copy that list to the clipboard and paste it into another program (Pages, MacJournal, TextEdit) the sort order changes.
    I work mostly in English, but my macbookpro keyboard is German, so I assume the problem is with the language settings. I've tried changing the system preferences for language and sort order, and that changes the sort order, but it doesn't get it right.
    Anyone have any ideas?
    Thanks

  • SORT ORDER WITHIN GROUPS

    Post Author: Kara
    CA Forum: General
    Hi,
    I am using version 9. I have designed a report based on an access control database. It shows a person's time in and time out, then totals these hours. My report is grouped as follows:
    Department
    Date/Time
    Unique ID
    The main data of the report is shown in group footer 3 (Unique ID) and is displayed in numerical order. I need to change the sort order to display by last name, first name but because I have grouped by unique ID I can't seem to be able to do it!
    Any help gratefully received,
    Kara

    Post Author: CoolTowers
    CA Forum: General
    I use a similar report to track service personnel who also have a unique ID.  I have mine set up as follows - maybe this'll help.
    I used selection expert to specify the dates I want to see. 
    Group 1 sorts on the unique ID. Instead of printing the unique ID field in the group header, I have Employee.EmpName.  They'll come out in their unique ID sort so the names might be a little out of order. If that's a problem you could put sort option on that field.
    Group 2 sorts by the Job ID, with the group header suppressed.
    Detail line has location, job id, date, time on, time off, total time in hours and if it's completed.
    Group 2 summarizes at date and amount at the job ID level.
    Group 1 summarizes at technician.
    I get very accurate reports to match against their hand written time cards.
    Perhaps if you re-arranged the grouping?

  • How to keep sort order in Shuttle item's source and destination boxes?

    I have defined a shuttle item on a page and the list of values in the source box is populated by a SQL with sort order specified. In the Settings of the shuttle item, Show Controls value is set to Moving Only instead of All. When a user moves selected values from the source box to the destination box or vice versa, the list of values does not maintain the original sort order. For example, if I have 26 values A through Z, a user can put value Z before A in the destination box. And when a user move A from the destination box to the source box, A is the last item in the source box. The reset button clears everything in the destination box and resets the source box to the original sorted list. This is not the solution that I am looking for. I would like to see the items in the source and destination boxes to maintain their original sort order all the time.
    Is it possible?
    APEX v4.0.1.00.03
    Oracle 11g (v11.2.0.1.0)

    Hi,
    See if this post help
    Re: Sort Shuttle Right
    Regards,
    Jari

  • Sorting Order for SAP Tables in DB2 database

    Dear Experts -
    ISSUE: When an ABAP program selects data from the DB into an internal
    table, it is changing the way the data is sorted. In other words, the
    internal table data is in a different sort order than what is in the
    DB. It is not working this way in all other non-production systems
    (DEV, QAS, SAX, etc).
    Temporary solution for the programs that have been identified as
    impacted: Use the ABAP Command 'sort' on the internal table.
    Permanent solution needed : Since it is impossible to identify all
    of the programs that will be impacted, we need PRD to work like DEV,
    QAS, SAX, etc. when selecting data into internal tables. The data
    should be in the same order as it is in the DB (sorted by the key).
    ADDITIONAL INFO: DB2 storage disks crashed a day before. H/W team recovered everything. We are facing this only after the recovery.
    Thanks,
    Dinesh

    can you please check in your code if the sql that is being sent has an order by clause .
    Please let us know the SQL statements that is basically used to fill up the internal table.
    When data is fetched from the database, it is not sorted always. Probably you had a clustered index on the tables and the clustering is not there now.
    Edited by: Ratnajit Dey on Dec 16, 2011 1:56 PM

Maybe you are looking for