Two Plus Two Older Archives  

Go Back   Two Plus Two Older Archives > General Gambling > Computer Technical Help
FAQ Community Calendar Today's Posts Search

Reply
 
Thread Tools Display Modes
  #1  
Old 06-21-2005, 07:28 PM
fluorescenthippo fluorescenthippo is offline
Senior Member
 
Join Date: Apr 2005
Location: 44s
Posts: 320
Default sorting a case sensative list alphabetically

I have a list of poker notes that i want to sort. each note is seperated by a return. I want to sort them alphabetically by the first word. If the first word is capitalized, it would come before lowercase words.

The list would then look something like this.
A
E
J
W
b
d
o
q

you get the idea. is there a program that will help me do this?
Reply With Quote
  #2  
Old 06-21-2005, 10:28 PM
BluffTHIS! BluffTHIS! is offline
Senior Member
 
Join Date: Nov 2004
Posts: 375
Default Re: sorting a case sensative list alphabetically

I assume what you want to do is manipulate a party/skin notes file and then be able to put it back the way they make it. I wrote a post about this in the zoo a while back and said that as far as I know neither MS Word or other word processors will alphabetize a list case sensitively. So you are probably SOL unless someone else comes up with an idea. Obviously the party software has a way to do it but I have no idea how. I have also tried using a sort on cells in excel, which should mirror acess, which has a case sensitive option, but what it does is merely put lowercase values immediately in front of corresponding uppercase once for the same letter, not all the lowers first then uppers.
Reply With Quote
  #3  
Old 06-21-2005, 10:47 PM
Larimani Larimani is offline
Member
 
Join Date: Sep 2004
Location: UK
Posts: 40
Default Re: sorting a case sensative list alphabetically

Lowercase letters have got different ASCII codes that uppercase ones...

Uppercase is ASCII#65-90 whereas lowercase is ASCII#97-122

It should be relatively easy to write a macro that sorts your list into 2 lists (uppercase and lowercase)... and then you can do an alphabetical sort on both list in Excel.

Unfortunately, my programming skills are too poor to write such macro.

There might be an easier way to do it...
Reply With Quote
  #4  
Old 06-22-2005, 12:13 AM
BluffTHIS! BluffTHIS! is offline
Senior Member
 
Join Date: Nov 2004
Posts: 375
Default Re: sorting a case sensative list alphabetically

This is a good suggestion and I did a quick google and found this link regarding sorting macros link though I haven't coded a macro in VBA before and don't know if the example one would do the trick but it seems like it might if you change the match_case arguement to true.
Reply With Quote
  #5  
Old 06-22-2005, 02:35 AM
fluorescenthippo fluorescenthippo is offline
Senior Member
 
Join Date: Apr 2005
Location: 44s
Posts: 320
Default Re: sorting a case sensative list alphabetically

damn. too bad im an electrical engineering major and not a cs one. i have no idea how to use that stuff. someone on 2+2 should make a program for this
Reply With Quote
  #6  
Old 06-22-2005, 11:33 AM
Guthrie Guthrie is offline
Senior Member
 
Join Date: Feb 2005
Posts: 471
Default Re: sorting a case sensative list alphabetically

It should be easy work for any database application. You just sort on upper(whatever). The upper() function causes the sort to see everything as upper case, but doesn't actually change the data.

I could sort it for you and send it back, but I assume you need something on an ongoing basis.
Reply With Quote
  #7  
Old 06-22-2005, 03:12 PM
MrBrightside MrBrightside is offline
Member
 
Join Date: May 2005
Posts: 65
Default Re: sorting a case sensative list alphabetically

I have used a shareware program, UltraEdit (like a super, super, notepad) for years. It will do this.
this:
Abe
bell
bell
fred
Fred
zee

Becomes:
Abe
Fred
bell
bell
fred
zee

you can dl a 30 day trial at www.ultraedit.com
Reply With Quote
  #8  
Old 06-22-2005, 03:48 PM
fluorescenthippo fluorescenthippo is offline
Senior Member
 
Join Date: Apr 2005
Location: 44s
Posts: 320
Default Re: sorting a case sensative list alphabetically

wow thanks, this is very helpful. i will have to buy this program
Reply With Quote
  #9  
Old 06-22-2005, 05:29 PM
MrBrightside MrBrightside is offline
Member
 
Join Date: May 2005
Posts: 65
Default Re: sorting a case sensative list alphabetically

no problem. If you do much maniupluation of text files, it's worth it. I program for a living, and i do most of my programming in this thing. It's got some powerful macro capabilities and there is a nice user community with lots of files to download.

Once, I wrote a macro in about 45 minutes to merge PokerStars notes files from my laptop and desktop (sync them up), for instance. Didn't take too long.
Reply With Quote
  #10  
Old 06-22-2005, 05:18 PM
tinhat tinhat is offline
Senior Member
 
Join Date: Apr 2005
Location: white courtesy phone
Posts: 288
Default Re: sorting a case sensative list alphabetically

[ QUOTE ]
I have a list of poker notes that i want to sort. each note is seperated by a return. I want to sort them alphabetically by the first word. If the first word is capitalized, it would come before lowercase words.

The list would then look something like this.
A
E
J
W
b
d
o
q

you get the idea. is there a program that will help me do this?

[/ QUOTE ]

If this is a plain text file and you have access to linux (or GNU tools installed on windows), from a csh prompt type what's bolded (where "list" is your text file name):

% mkdir list.tmp && foreach entry (`cat list`)
foreach? touch list.tmp/$entry
foreach? end && ls -1 list.tmp > list.new

"list.new" contains your results.

If you used emacs you'd simply load the file, set "sort-fold-case" to nil and run "sort-lines". Done.

Mike
Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 02:26 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.