Alpha Software Mobile Development Tools:   Alpha Anywhere    |   Alpha TransForm subscribe to our YouTube Channel  Follow Us on LinkedIn  Follow Us on Twitter  Follow Us on Facebook

Announcement

Collapse

The Alpha Software Forum Participation Guidelines

The Alpha Software Forum is a free forum created for Alpha Software Developer Community to ask for help, exchange ideas, and share solutions. Alpha Software strives to create an environment where all members of the community can feel safe to participate. In order to ensure the Alpha Software Forum is a place where all feel welcome, forum participants are expected to behave as follows:
  • Be professional in your conduct
  • Be kind to others
  • Be constructive when giving feedback
  • Be open to new ideas and suggestions
  • Stay on topic


Be sure all comments and threads you post are respectful. Posts that contain any of the following content will be considered a violation of your agreement as a member of the Alpha Software Forum Community and will be moderated:
  • Spam.
  • Vulgar language.
  • Quotes from private conversations without permission, including pricing and other sales related discussions.
  • Personal attacks, insults, or subtle put-downs.
  • Harassment, bullying, threatening, mocking, shaming, or deriding anyone.
  • Sexist, racist, homophobic, transphobic, ableist, or otherwise discriminatory jokes and language.
  • Sexually explicit or violent material, links, or language.
  • Pirated, hacked, or copyright-infringing material.
  • Encouraging of others to engage in the above behaviors.


If a thread or post is found to contain any of the content outlined above, a moderator may choose to take one of the following actions:
  • Remove the Post or Thread - the content is removed from the forum.
  • Place the User in Moderation - all posts and new threads must be approved by a moderator before they are posted.
  • Temporarily Ban the User - user is banned from forum for a period of time.
  • Permanently Ban the User - user is permanently banned from the forum.


Moderators may also rename posts and threads if they are too generic or do not property reflect the content.

Moderators may move threads if they have been posted in the incorrect forum.

Threads/Posts questioning specific moderator decisions or actions (such as "why was a user banned?") are not allowed and will be removed.

The owners of Alpha Software Corporation (Forum Owner) reserve the right to remove, edit, move, or close any thread for any reason; or ban any forum member without notice, reason, or explanation.

Community members are encouraged to click the "Report Post" icon in the lower left of a given post if they feel the post is in violation of the rules. This will alert the Moderators to take a look.

Alpha Software Corporation may amend the guidelines from time to time and may also vary the procedures it sets out where appropriate in a particular case. Your agreement to comply with the guidelines will be deemed agreement to any changes to it.



Bonus TIPS for Successful Posting

Try a Search First
It is highly recommended that a Search be done on your topic before posting, as many questions have been answered in prior posts. As with any search engine, the shorter the search term, the more "hits" will be returned, but the more specific the search term is, the greater the relevance of those "hits". Searching for "table" might well return every message on the board while "tablesum" would greatly restrict the number of messages returned.

When you do post
First, make sure you are posting your question in the correct forum. For example, if you post an issue regarding Desktop applications on the Mobile & Browser Applications board , not only will your question not be seen by the appropriate audience, it may also be removed or relocated.

The more detail you provide about your problem or question, the more likely someone is to understand your request and be able to help. A sample database with a minimum of records (and its support files, zipped together) will make it much easier to diagnose issues with your application. Screen shots of error messages are especially helpful.

When explaining how to reproduce your problem, please be as detailed as possible. Describe every step, click-by-click and keypress-by-keypress. Otherwise when others try to duplicate your problem, they may do something slightly different and end up with different results.

A note about attachments
You may only attach one file to each message. Attachment file size is limited to 2MB. If you need to include several files, you may do so by zipping them into a single archive.

If you forgot to attach your files to your post, please do NOT create a new thread. Instead, reply to your original message and attach the file there.

When attaching screen shots, it is best to attach an image file (.BMP, .JPG, .GIF, .PNG, etc.) or a zip file of several images, as opposed to a Word document containing the screen shots. Because Word documents are prone to viruses, many message board users will not open your Word file, therefore limiting their ability to help you.

Similarly, if you are uploading a zipped archive, you should simply create a .ZIP file and not a self-extracting .EXE as many users will not run your EXE file.
See more
See less

ALPHAB. ORDER= �, e, �, etc.

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    ALPHAB. ORDER= �, e, �, etc.

    I need to order a list (table) by alphabet, the problem is that I�m in France and de alphabet includes letters like �, �, �, �, etc. and the normal order sends to the end of the list all of those letters.
    Could some body tell me, if it is possible to change the order rules, to obtain a list a, �, b, c, d, e, �, �, etc.?

    #2
    RE: ALPHAB. ORDER= �, e, �, etc.

    If you just need to set an index order, you can reorder the keys by using either translate() or some CHR() and ASC() expression to convert values to effectively reorder the data

    Regards,

    Ira J. Perlow
    Computer Systems Design & Associates
    [email protected]
    Regards,

    Ira J. Perlow
    Computer Systems Design


    CSDA A5 Products
    New - Free CSDA DiagInfo - v1.39, 30 Apr 2013
    CSDA Barcode Functions

    CSDA Code Utility
    CSDA Screen Capture


    Comment


      #3
      RE: ALPHAB. ORDER= �, e, �, etc.

      Referring back to my (long ago) college days, and the ACSII table of values, I don't think that you can reset the order. Each unique character is assigned a specific number code. Upper case letters sort before lower case letters, etc. "Special" characters are assigned very high numbers, so when sorting, they come last. Unless you can figure out how to modify the ASCII table assignments, I think you are out of luck. If you did modify the table, Other things on your system might get very weird.

      Tom

      Comment


        #4
        RE: ALPHAB. ORDER= �, e, �, etc.

        Hi,

        You need a version of Windows that uses the right code page for French, then it would do the alphebetising right.

        Windows has local versions, whose interface is in the local language, and there are what they call "enabled" whose interface could be set either to the local language or english. Either way it would alphebetise right.I use a hebrew enabled version of Windows 98, and it alphebetises hebrew or english charachters correctly.

        Comment


          #5
          RE: ALPHAB. ORDER= �, e, �, etc.

          Hi all,

          Like many others, I have struggled with this one. It is relatively easy to convert a single letter. I created a table. Then it is trivial to write a lookup expression that takes an accented character and returns the the unaccented version (or its ascii value).

          However, I find it more difficult to process a multi-character expression. All I can come up with is to step through the string and see if each character has an accent and if so use the lookup function to convert it. Slow and ugly.

          Since all those sort pages are in Windows (somewhere)it must be possible to refer to them. Ira, is this what you meant when you mentioned to the translate function. If so, how do you call it? I guess you use declare but then what?

          Thanks very much,
          Bill
          Bill Hanigsberg

          Comment


            #6
            RE: ALPHAB. ORDER= �, e, �, etc.

            Here's another approach. It's a trifle inelegant but it is practical so long as your record size permits you to waste a field.

            Suppose you want to index on lastname and the names contain accents. You could add another field--lastname_key--and write to it using code attached to the on_change event of the lastname field. The code needs to pass unaccented characters through and substitues for the accented ones (eg. "e" for "�").

            You would simply index and run your sorts on the lastname_key field.

            Notwithstanding the above, I am certain there is a better way.

            Bill
            Bill Hanigsberg

            Comment


              #7
              RE: ALPHAB. ORDER= �, e, �, etc.

              Hi Bill:
              Could you be more precise about on_change code? I'm trying a similar solution but it is not so good: I created one field, and because I�m listing French verbs and there are not so much accented letters, I changed manually those letters and then I sort this new field
              thanks
              juan

              Comment


                #8
                RE: ALPHAB. ORDER= �, e, �, etc.

                Hi
                I all ready have the french version of Windows 98, do you have any idea?

                Comment


                  #9
                  RE: ALPHAB. ORDER= �, e, �, etc.

                  Hello again,

                  I have been playing around with this. I was convinced this would be easy which I should have recongnized as a clear sign of impending doom.

                  I wrote the following function which is incomplete (leaves out lots of accented characters) but serves to verify an approach.

                  function no_accents as C(input_string as C)
                  ' Replaces accented characters with unaccented equivalents for ordering

                  tmpstr = ""
                  for i = 1 to len(input_string)
                  vChar = substr(input_string,i,1)
                  select
                  case vChar = "�".or.vChar = "�".or. vChar = "�"
                  vChar = "e"
                  case vChar = "�"
                  vChar = "c"
                  case vChar = ""
                  vChar = "�" .or. vChar = "�"
                  vChar = "a"
                  case else
                  vChar = vChar
                  end select

                  tmpstr = tmpstr+vChar
                  next

                  no_accents = tmpstr

                  end function


                  And it "works" (after its fashion). The following is from the interactive window.

                  ?no_accents ("�l�ve")
                  = "eleve"

                  Great. But don't--repeat DO NOT--use it in an index expression as it will shut down Alpha and freeze your machine, or at least that's what happened to mine. I can also report that it will not work in a saved update operation, at least as created by the genie.

                  I thought I might work around the problem by using the ASC function but the interactive window gives

                  ?asc("�")
                  = -23.000000

                  This is not something you want to see.

                  So the question I would ask those whose expertise is at a higher plane than my own is simply, why does a valid expression in the interactive window fail in an index expression?

                  Thanks in advance to whomever is able to shed some light on this.

                  Bill
                  Bill Hanigsberg

                  Comment


                    #10
                    RE: ALPHAB. ORDER= �, e, �, etc.

                    Whoops,

                    I just noticed my typo. I'll repair it and see what happens.

                    Sorry it it's a false alarm.

                    Bill
                    Bill Hanigsberg

                    Comment


                      #11
                      RE: ALPHAB. ORDER= �, e, �, etc.

                      Hi again,

                      Well my previous question was a false alarm. The cleaned up function does work in an index expression.

                      function no_accents as C(input_string as C)
                      ' Replaces accented characters with unaccented equivalents for sorting and indexing

                      tmpstr = ""
                      for i = 1 to len(input_string)
                      vChar = substr(input_string,i,1)
                      select
                      case vChar = "�".or.vChar = "�".or. vChar = "�"
                      vChar = "e"
                      case vChar = "�"
                      vChar = "c"
                      case vChar = "�" .or. vChar = "�"
                      vChar = "a"
                      case else
                      vChar = vChar
                      end select

                      tmpstr = tmpstr+vChar
                      next

                      no_accents = tmpstr

                      end function

                      It isn't fast but then, if you need it you need it. In any case, the speed can be improved by changing the order of the case statements since most characters are unaccented. I'll post an improved--and more complete--version tomorrow or Sunday.

                      Bill
                      Bill Hanigsberg

                      Comment


                        #12
                        RE: ALPHAB. ORDER= �, e, �, etc.

                        Bill,

                        What I meant by translate was to essentially convert the string as you are basically doing. For speed in translating, I probably would create a variable array with the array index being the current ascii value and it's value being the new one. STRITRAN() and STRTRAN() would probably be the best functions to convert them. Then you don't have to parse the string manually, but depending upon size and number of replacements required may take more or less time.

                        Also, code like the following that you wrote;

                        vChar = "�".or.vChar = "�".or. vChar = "�"

                        would be much faster expressed as

                        vChar $ "���"

                        Regards,

                        Ira J. Perlow
                        Computer Systems Design & Associates
                        [email protected]
                        Regards,

                        Ira J. Perlow
                        Computer Systems Design


                        CSDA A5 Products
                        New - Free CSDA DiagInfo - v1.39, 30 Apr 2013
                        CSDA Barcode Functions

                        CSDA Code Utility
                        CSDA Screen Capture


                        Comment


                          #13
                          RE: ALPHAB. ORDER= �, e, �, etc.

                          Hi Ira,

                          Thanks very much for the timely advice which I will certainly use.

                          Alas, I may have further need for your advice.

                          All the best,
                          Bill
                          Bill Hanigsberg

                          Comment


                            #14
                            RE: ALPHAB. ORDER= �, e, �, etc.

                            Ira,

                            Another point. Creating an array of ascii values may not work in this case as the asc() function seems not to work with the accented characters.

                            Or am I missing something here?

                            Thanks again,
                            Bill
                            Bill Hanigsberg

                            Comment


                              #15
                              RE: ALPHAB. ORDER= �, e, �, etc.

                              Bill,

                              I'm a bit surprised that ASC() doesn't work, but can't say I've tested it either. Nevertheless, there is another way to skin the cat, using something like;


                              function no_accents as C(input_string as C)
                              ' Replaces accented characters with unaccented equivalents for
                              ' sorting and indexing

                              oldvals="������"
                              newvals="eeecaa"

                              tmpstr = ""

                              for i = 1 to len(input_string)
                              vChar = substr(input_string,i,1)

                              position=AT(vChar,oldvals)
                              if position>0
                              Vchar=SUBSTR(newvals,position,1)
                              end if

                              tmpstr = tmpstr+vChar
                              next

                              no_accents = tmpstr

                              end function



                              Regards,

                              Ira J. Perlow
                              Computer Systems Design & Associates
                              [email protected]
                              Regards,

                              Ira J. Perlow
                              Computer Systems Design


                              CSDA A5 Products
                              New - Free CSDA DiagInfo - v1.39, 30 Apr 2013
                              CSDA Barcode Functions

                              CSDA Code Utility
                              CSDA Screen Capture


                              Comment

                              Working...
                              X