The muse took me, and I have implemented sort for floating point fields in a CSV
file.

Please see the updated code:
http://vim.wikia.com/wiki/Working_with_CSV_files

OK, it's a bit long, but it's amazing code! Of course you need a version of Vim 
that
supports floats. The :version command should show +float in its output (get Vim 
7.2
if you don't have it).

A bit of testing would be good ... please let me know how you go.

I'm using Vim's str2float() to convert a field to a float. A field like 
"1.25junk"
will be regarded as 1.25. A field like "junk1.25" will be regarded as a string 
and
will sort before numbers.

John


--~--~---------~--~----~------------~-------~--~----~
You received this message from the "vim_use" maillist.
For more information, visit http://www.vim.org/maillist.php
-~----------~----~----~----~------~----~------~--~---

Reply via email to