Search
Code Directory
 ASP
 ASP.NET
 C/C++
 CFML
 CGI/PERL
 Delphi
 Development
 Flash
 HTML
 Java
 JavaScript
 Pascal
 PHP
 Python
 SQL
 Tools
 Visual Basic & VB.NET
 XML
New Code
Inventory Manager For Dynamics CRM 4.0
Dockit Migrator for SharePoint 11.8.6905
Australia Post Shipping For Magento 2 1.0.0
StarTrack Shipping For Magento 2 2.0.0
Mydala script 1.3
dotConnect for FreshBooks 1.8
Odoo Kingfisher Theme 1.0
Bitcoin Mining Software - Bitcoin Mining Script 1.0.2
Excel Add-in for Magento 1.7
Excel Add-in for MailChimp 1.7
Devart Excel Add-in for QuickBooks 1.7
Excel Add-in for PostgreSQL 1.7
Devart Excel Add-in for MySQL 1.7
Devart Excel Add-in for NetSuite 1.7
Excel Add-in for Salesforce 1.7
Top Code
ATN Site Builder 3.0
ATN Resume Finder 2.0
PHP Review Script 1.0
Invoice Manager by PHPJabbers 3.0
ICPennyBid Penny Auction Script 4.0
Excel Add-in for PostgreSQL 1.1
Excel Add-in for Salesforce 1.1
Excel Add-in for MailChimp 1.1
Aglowsoft SQL Query Tools 8.2
Classified Ad Lister 1.0
Solid File System OS edition 5.1
ADO.NET Provider for ExactTarget 1.0
Deals and Discounts Website Script 1.0.2
dotConnect for FreshBooks 1.8
Excel Add-in for Magento 1.6
Top Rated
phpEnter 5.1.
Single Leg MLM 1.2.1
Azizi search engine script PHP 4.1.10
Paste phpSoftPro 1.4.1
Extreme Injector 3.7
Deals and Discounts Website Script 1.0.2
ADO.NET Provider for ExactTarget 1.0
Solid File System OS edition 5.1
Classified Ad Lister 1.0
Aglowsoft SQL Query Tools 8.2
Invoice Manager by PHPJabbers 3.0
ICPennyBid Penny Auction Script 4.0
PHP Review Script 1.0
ATN Resume Finder 2.0
ATN Site Builder 3.0
Sorting big files the Python 2.4 way 
File ID: 65856






Sorting big files the Python 2.4 way 
Download Sorting big files the Python 2.4 way http://code.activestate.com/recipes/310792-a-native-implementation-of-threadinglock-and-threa/?in=lang-pythonReport Error Link
License: Freeware
Downloads: 4
Submit Rating:
Sorting big files the Python 2.4 way  Description
Description: This recipe can be used to sort big files (much bigger than the available RAM) according to a key. The sort is guaranteed to be stable on Python 2.3.

License: Freeware

Related: Files

O/S:Windows

Downloads: 4



More Similar Code

This is just a rewrite of Recipe 466302 "Sorting big files the Python 2.4 way", taking advantage of heapq.merge, context managers, and other niceties of newer Python versions. It can be used to sort very large files (millions of records) in Python. No record termination character is required, hence a record may contain embedded binary data, newlines, etc. You can specify how many temporary files to use and where they are located.



Python 2.4 has added a new feature to handle the problem where you needed to do
a sort based off of part of the data. In effect, it has simplified the Schwartzian Transform
(which I learned many years ago from an perl article



Python 2.4 adds a new builtin function sorted(), which can make obtaining the items of a dictionary sorted by key or value a single line operation.



The following code shows why you would want to use a heap instead of a list and the basics of using heapq in python with some additions for python 2.4( I've cleaned this up from earlier to make it hopefully clearer.)



New to python 2.4 is the string.Template class. It is similar to the formatting python already had in which the % operator with strings was used in a recognizable sprintf style of formatting from C. In addition to format types, you also had a...



Python 2.4 introduces a new threading.local() type - a thread local storage. This is a simple demonstration of this.



Translation from english to brazilian-portuguese of the Python 2.5.2 DocumentationTraduo do ingles para o portugus da Documentao de Python 2.5.2



Doctest and unittest are like 2 extremes of testing your python
code. One is simple and intuitive and the other is powerful and
requires more formality. In Python 2.4, doctest, builds in some of the
power of unittest, perhaps...



Cake is a build system that combines the flexibility of Python build scripts with an incremental build speed that matches build systems written in C/C++. It requires Python 2.4-3.2 and natively supports Windows, Linux, Mac, Cygwin, MSVC and GCC.



Implements the three standard relational join algorithms: nested loops join, hash join, and merge join, using the iterator algebra support in Python 2.4. This recipe presents code that can be used for inner join, left outer join, full outer join,...

User Review for Sorting big files the Python 2.4 way
- required fields
     

Please enter text on the image