Correct sort numbers stored as text

I have a few numbers of documents stored as text values that I want to sort in the correct order. However, what I get is 1-101, 1 - 10A, 1-11, 1-14, 1-17, 1 - 17A .i, 1-19, 1-2, 1-21, 1-30, 1.35, 1.47, 1-4-A, 1-5, 1-7, 1 - A, 1 B, 1 - C. This is the title of the document ID, that is why the inconsistancy. I wish they would have done better with it, but these docs old ar and and all I have to work with. It is just a small set. I have a lot more starting with 2, 3 and so on.

I was wondering how can I get these to be sorted in the correct order of smallet to the largest. I.E.
1-2, 1-4-A, 1-5, 1-7, 1-10, 1-11, 1-14, 1 - 17A, 1 - 17A .i, 1-19, 1-21, 1-30, 1.35, 1.47, 101, 1-1-A, 1 B, 1 c

The ABC may be at the beginning or at the end is okay as long as the figures are correct.

Is this possible. Thanks for the help.

It is stored in a MS Access database. I think I knew how to do things in the right order. Since there is an inconsistancy in the naming convention, I came a way to make it consistent. I have 2 columns, 1 with the document ID number and one with just the number of the document (1-17 has 17 for the second column). This way I can fool all initially based on the second column as they are entirely digital and so for the first column of I duplicated in the second column.

For example, 1 - 17A and 1-17A .i have all two 17 in the second column, but by sorting two columns, the order is correct and 1 - 17A comes before 1-17A .i. For document ID's that do not have a number and a letter such ast 1A, I assing a certain number of 1000A, 1001 for B and so on. In this way they have a number too and will usually appear at the end of the list.

Tags: ColdFusion

Similar Questions

  • Digital data stored as text in Excel

    Dear community LabVIEW,

    Let me ask you a help with the following problem. I have record of control data Table in Excel, using Microsoft Office Generation Toolkit. To do this, I have model - basically in the Excel template file, there are up to 8 tables, and I need to write different data for them. So, I use the code, I have add in attachments - of course, he is slightly reworked for the forum, but in the application, it uses the same parts of code. Data are save to the model, but - numerical values are displayed in Excel as text. And Excel "knows" it's numeric values - and proposes to convert it to digital, as you can see on the screenshot... Formatting cells, where I write data, doesn't help you no - b/c when I implemented cells as 'General' (basically, digital Formate) format, he said, that the numbers are stored as text - format b/c cells is digital, no text.
    And what is more interesting - when I save no Table, but a digital 2D painting in Excle file through the function, I get the same behavior - data digital is stored as text...

    I may, some incorrect settings in Excel. But maybe, it can be solved in progrmatically. Could someone help, please?

    Thanks in advance!

    The solution was simple, thanks to a guy who helped me - need to replace point by point. Subsequently, everything has been saved successfully.

  • number stored as text

    Hi ~

    When write a MS Excel table, the total number stored as text that you can see the green flag on the upper left corner of each cell, it's cause the fomula in the upper cell not feasible.

    the code that allows to write Excel as below:

    have you even seen this before? pls advice, thx!

    There's a hack you can use - after having written values, read data from the Value2 property and write what you read the property (this is so has write, read B, writing B). I don't know why, but it works. Probably a quirk in how Excel types auto-formats.

  • Allow numbers in the text field

    Hi all

    I want to allow numbers in the text field using the BACKSPACE and delete keys to change.

    --> the code below does not allow alphabets but when I type a character in-between the numbers I add.

    -> and the other question is, if I select all of the text in the text field and press on any non-numeric key (for example: alphabets or special characters) it adds, but if I select all the text and if I type in the text box it won't add them.


    for example: I have 253 typed in the textfield If I try to type the alphabets it will not add

    but when I type in between the figures he adds 25java3

    CODE:

    public void changed (ObservableValue <? extends number > observable, oldValue, newValue number number) {}

    If (newValue.intValue () > oldValue.intValue ()) {}

    char ch = allocatevaluesText.getText () .charAt (oldValue.intValue ());

    System.out.println ("length:" + oldValue + "" + newValue + "" + ch);

    Check if the new character is the number or other

    If (!) () ch > = '0' & & ch < = '9')) {}

    If it's not previous number then just setText

    allocatevaluesText.setText (allocatevaluesText.getText () .substring (0, allocatevaluesText.getText () .length () - 1));

    }

    }

    Hi ATS the following:

    {code}

    final tf TextField = new TextField();
    tf.addEventFilter (KeyEvent.KEY_TYPED, new EventHandler() {}
    @Override
    {} public void handle (KeyEvent t)
    If (! t.getCharacter () .matches ("\\d")) {}

    t.consume ();
    }
    }
    });

    tf.textProperty () .addListener (new ChangeListener() {}
    public void changed (ObservableValue observable, String oldValue, String newValue) {}
    System.out.println ("new text:" + newValue);
    try {}
    int a = Integer.parseInt (newValue);
    } catch (Exception e) {}
    tf.setText (oldValue);

    }
    }
    });

    {/ code}

  • Report showing the numbers instead of text.

    Hi all

    We have a planning application. I've created a report for employees, their hiring months smartview justification and man. I tried to create a report through connection to the essbase server. In the report, I had random numbers for the text data (such as 1431 for justification of an employee hiring). Later I discovered that text data has been loaded through smartview to planning server and not to the Essbase server. This is probably the reason why I see (index) numbers of text fields.

    Is there a way to still generate the essbase Server report, or do we have to load these data to essbase app of the planning application?

    Like Michael said, you need to use the connection of planning. The smart lists used in planning are not in Essbase. Essbase stores smartlist not text value identification number.

  • Line numbers in the text

    Hello world

    I am building a Web site for former analysis University poems and letters. I need to add the line numbers in the text of the poems/letters I display - it works fine in Word, but I do not know how to apply line numbers in Dreamweaver. I'd be keen to set up as a CSS style, but I'm not really sure where to start. Any tips?

    Thank you
    Ness

    Not wide. Close actually.

    --
    Murray - ICQ 71997575
    Adobe Community Expert
    (If you * MUST * write me, don't don't LAUGH when you do!)
    ==================
    http://www.projectseven.com/go - DW FAQs, tutorials & resources
    http://www.dwfaq.com - DW FAQs, tutorials & resources
    ==================

    "Joe Makowiec" wrote in message
    News:[email protected]...
    > October 23, 2008 in macromedia.dreamweaver, Murray * ACE * has written:
    >
    > Do you know if it is possible to use CSS to design?
    >>
    > Is not what CSS.
    >
    > Actually:
    >
    > http://www.w3.org/TR/CSS21/generate.html
    >
    > I'm not sure how wide browser support is still, though.
    >
    > --
    > Joe Makowiec
    > http://makowiec.net/
    > Email: http://makowiec.net/contact.php

  • I want to sort a file of text editing

    Use: Mac OS X El Captan (10.11.4)

    Office of the Registrar the County gave me the voter information on some 200 000 voters in our County.  The information is on two discs. One is in the form of text editing; the other is in CSV format.  Unfortunately, when I open the CSV disc, which is sortable on any field, it includes only info registration for 65 538 voters, is less than 1/3 of the voters.

    When I reconnected the CSV disc to the person who gave the information and explained that the CSV disk only displays information for 65 538 voters, she put the drive in his PC, to confirm that she had copied a completeness of the CSV file on the disk. 200 000 voters appeared on his PC!

    I have concluded that the CSV file doesn't have to be compatible with the Apple software.  The instructions of the Office of the Registrar explain how to convert the file changing text in the CSV file, using the Windows software.  Unfortunately, I have no Windows software installed on my iMac.  The Office of the Registrar also stated that it had taken 10 hours to create the CSV file.

    Is it possible for me to convert the file changing text in a Numbers spreadsheet sortable?

    FWIW, I normally do not work with spreadsheets, but test a few large .csv files, numbers seem to have a limit of 64 k lines so convert the file of text editing will not help. On the other hand, LibreOffice seems to have more than 1 million more lines, so you should be able to sort your files in OL.

    Someone else may have more information.

  • How to: Sort numbers in ascending in a generated list order

    Greetings! How can I set up a list of paragraphs generated so that it sorts in ascending order of true? What I want is:

    1.1

    1.2

    1.3

    1.4

    1.5

    1.6

    1.7

    1.8

    1.9

    1.10

    I tried all the stuff I can think with the listed on the reference page sort order. But all I can get something that sorts by individual number (without taking into account the numerical value) as:

    1.1

    1.10

    1.11

    1.2

    1.20

    1.21

    1.3

    Any help is very appreciated!

    TMS,

    To me it looks like hand-numbering of requirements using a method that allows a correct alphabetical sorting, e.g. 01, 02, if you do not expect more than 99 titles.

    For the moment, I don't know better.

    -Michael

  • Firefox displays only numbers and no text in some web sites. whereas the Internet shows explore them all to the same web site. What is the solution?

    When I click on a link in a web site, it is supposed to show the details on another page of the same website with text and numbers. But it only shows numbers. Why?

    Start Firefox in Safe Mode to check if one of the extensions (Firefox/tools > Modules > Extensions) or if hardware acceleration is the cause of the problem (switch to the DEFAULT theme: Firefox/tools > Modules > appearance).

    • Do not click on the reset button on the start safe mode window or make changes.

    Alternatively, you can try to start the computer in safe mode Windows with network support (on the startup screen, press F8) as a test to see if it helps in the case where your security (firewall, antivirus) software causes this problem.

  • Extraction of specific numbers of a text file?

    I have a text file with repetition of the data sets.  Each is long 4 lines, with line 1 which contains a title, line 2, with a constant that identifies the data, line 3 has a single number and line 4 has two digits corresponding to a max and min.  Is there a way I can extract the line numbers 2, 3 and 4 separately to create a table for each?  So far, I used file text, connected to a loop playback, containing analysis of string function.  I don't know how to choose every 4th line of the file to obtain common aggregate.  I am new to Labview, so any advice is much appreciated!  Thank you.

    You can also use text file VI and the Decimate function table 1 d.

    Ben64

    As Moderator1983 said that a sample of the data would be useful, min and max, separated by space, tab, comma. Want you as min and max in separate tables? ...

  • Windows 8 applications does not appear correctly. background becomes black and text becomes blurry and apps close automatically

    WINDOWS APPLICATIONS 8 DOES NOT PROPERLY

    • the black background become apps. for example, in app people white background become black
    • the text becomes blurry and apps works slowly
    • While only game apps work properly
    • All these take place but live tiles work properly

    After an update the drivers for my graphics card, I was disappointed to see that the problem was not resolved.

    Then, a few days later I completely uninstalled the drivers for my graphics card and reinstalled them.

    And here, my apps 'Modern' redisplay correctly.

  • Fill a field with the results of the other (sort and add custom text)

    I have a PDF form with many fields popup asking 'Yes', 'Maybe' or 'no '. I need a way to collect the answers and sorting, all the 'yes' first of all, that all the 'maybe', all the 'no '. When I need after that sort of response of three, is put in a 'Results' field with the container of the ToolTips for each popup and the ability to add a "BOLD" text, between three sorted responses.

    I have found some javascript in the forum here to collect data from field only. It seems to be easy to modify if you have several fields to collect/sorting/extract.

    Assistance or management to do will be appreciated.

    Thank you!

    Assuming that you have 50 menus named A1, A2... A50 and each drop-down list has three elements (Yes, maybe, no), you could do something like:

    Initialize object to contain the info of the answer

    var oResponse = {}

    'Yes': [],.

    "Maybe": [],.

    ['No':]

    };

    var i, f;

    Browse fields (A1, A2... A50)

    for (i = 1; i<= 50;="" i="" +="1)">

    Get a reference to the current field

    f = getField ("A" + i);

    Add ToolTip text of the current field to the corresponding table in the response object

    oResponse [f.valueAsString] .push (f.userName);

    }

    Generate the output string

    aOutput var = [];

    If (oResponse ['yes'] .length > 0) aOutput.push ("It's the priority YES\r" + oResponse ["Yes"] .join ("\r"));

    If (oResponse ["Maybe"] .length > 0) aOutput.push ("It's the priority MAYBE\r" + oResponse ["Maybe"] .join ("\r"));

    If (oResponse ['No'] .length > 0) aOutput.push ("It's the priority NO\r" + oResponse ["No"] .join ("\r"));

    Enter the results

    getField("Results").value = aOutput.join("\r\r");

  • space between bullets and numbers and the text in the form

    Where can I go to format the spacing between bullets and numbers, and the following text?

    Bullets and Numbers.jpg

    Thank you

    Open the two CSS files in a text editor and search for differences. Do the same with the subjects. There will be a difference somewhere.

    After back if still stuck.

    See www.grainge.org for creating tips and RoboHelp

    @petergrainge

  • Sort Table data with text fields (form)

    I googled and searched forms of days for a response, but were unsuccessful.

    The only wire that I found being a year old, I wanted to start a new instead of bumping an old

    Ref: http://forums.adobe.com/message/3000436

    I'm looking for a script to sort the data in a form that is based on user input.

    The shape is just a table with multiple rows and columns of 3-5 (according to the dept) it's used)

    Using the thread referenced above, I was able to get a static table to sort, but I need to have all the fields to be text fields and the users enters the data.

    The example of the other thread static:

    http://forums.adobe.com/servlet/JiveServlet/downloadImage/2-3000436-35301/364-128/Untitled.png

    I'll use the same layout, just need to be a shape rather than static.

    If anyone can help or point me in the right direction, it would be great.

    Update #1:

    I find this page:http://cookbooks.adobe.com/post_Sorting_tables_in_dynamic_PDF-18993.html

    I'm the kind of work and it seems to be mostly what I look for, but how to deal with field empty?

    For example, the last three lines are empty (no data) the genre fails.

    Here is the code of the page, how can I change to fix the empty fields?

    ------------------------------------------------

    pass var = 0; column index

    var num = false; Is the numeric column

    var OrderAsc = true; Sort order

    function SortTable (tableRef, colIndex, isNumeric, CSA)

    {

    Try

    {

    Col = colIndex;

    NUM = isNumeric;

    OrderAsc = Asc;

    String variable that contains the data of the form as the XML string

    data var = tableRef.saveXML ('pretty');

    A XML variable contains the deserialized XML data

    xmlData var = xfa.datasets.createNode ("dataGroup", tableRef.name);

    xmlData.loadXML (data);

    Number of rows in the table

    var rowsCount = xmlData.nodes.length;

    Number of columns in the table

    passes of the var = xmlData.nodes.item (1).nodes.length;

    Two dimension table contains data of the complete table

    Master of var = new Array();

    Fill in the chart with XML data

    for (var i = 1; i < rowsCount; i ++)

    {

    Master [i-1] = new Array();

    for (var j = 0; j < passes; j ++)

    {

    Master [i-1] [j] = xmlData.nodes.item (i).nodes.item (j) .value;

    }

    }

    Sort the table 2D

    Master.sort (sortFunc);

    Re-fill the XML variable with data in table

    for (var i = 0; i < master.length; i ++)

    {

    for (var j = 0; j < master [i] .length; j ++)

    {

    xmlData.nodes.item(i+1).nodes.item (j) .value = master [i] [j];

    }

    }

    Change the data in the table and the back of the form

    var result = xmlData.saveXML ('pretty');

    tableRef.loadXML (result, 1, 1);

    XFA. Form.remerge ();

    } catch (e)

    {

    App.Alert (e)

    }

    }

    Customize the sort function to manage the 2D array and numeric columns

    function sortFunc (a, b)

    {

    var x = a [col];

    var y = b [col];

    Try

    {

    If (num)

    {

    x = parseInt (a [col]);

    y = parseInt (b [col]);

    }

    } catch (e) {}

    If (OrderAsc)

    {

    return x == y? 0: (x < y?-1: 1)

    }

    on the other

    {

    return x == y? 0: (x < y?-1: 1)

    }

    }

    Solution found!

  • Cannot enter numbers in a text field

    Problem: I can't get into all the numbers in my entry!  Only letters!

    Details:

    The entrance of the fields are a 'classic' input field and part of a Flash application, I've done the year last for a customer. The Flash has been done with Flash CS4 on a Mac OSX 10.4 and published last year and has worked throughout the year.

    At one point recently, I've upgraded to Flash CS5 (this time on a PC), and I also had to re - compile the Flash application for some reason (a new image in the application). I left only publication (Flash 9, AS3) and re-released settings the Flash and set up direct. I can say that everything was fine.

    Now the customer comes to tell me that they cannot enter the numbers on the fields, only the letters!

    Outside the transition to CS5 or an upgrade to Flash Player in the browser, I can't imagine what would cause a problem.

    To solve this, I noticed for the first time the function in 'TLF text'. I've never used, but when I copy the form MC in a test file and run it with TLF fields, they accept all characters, including numbers. When I pass a field back to the classic text, I can enter is more numbers.

    What gives?

    Any info out there?

    Thanks in advance!

    Make sure you're incorporation numbers as well as letters.  If you are, then you have a restrict property assigned to your textfield with code.

Maybe you are looking for

  • License Manager NOR does not; It performs a query for the current license status, said

    I currently have the evaluation version of Labview. I tried to use a volume of my University license by typing the name of the server in the License Manager NEITHER, but after that, whenever I try to open the License Manager, it seems that he has sla

  • Upgrade to service pack 1 for 1 has on Windows XP

    We never improved from 1 to 1 has and now can't go to service pack 3.  Is there a way I can get service pack 1 has, seems to give me the run around on the site to upgrade Windows.  I know there is probably no support for it and I'm short late medium

  • How to find Skype on Skype menu bar?

    in Skype, have windows vista basic, cannot find the Skype menu bar?

  • Cover of compact with xperia z5 SCR44 style does not work on Android 6

    Hello people, after that I got my update (marshmallow), my cover has stopped working. Basically, I can accept calls but nothing more. The screen is great, no camera. He worked in 5.1.1 android, but not now. I have reset my phone with PC Companion and

  • HP 320-1050 heatsink required

    Hello I'm working on solving a problem of overheating with a TouchSmart 320-1050.  The problem seems to be with the heatsink that is not dispursing the heat to the fins.  I'm looking to replace the radiator, part number 655227-002.  I was told the se