Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options
 
PerlMonks  

Re: Using indexing for faster lookup in large file (PP < 0.0005s/record)

by BrowserUk (Patriarch)
on Feb 28, 2015 at 11:33 UTC ( [id://1118165]=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    #! perl -sw
    use strict;
    ...
    print( OUT pack 'NQ', m[^(\d+),], $pos ), $pos = tell( IN ) while <IN>
    +;
    
    close OUT; close IN;
    
  2. or download this
    #! perl -slw
    use strict;
    ...
    C:\>1118102-searcher -N=10000 30GB.dat 30GB.idx | find /v "Record"
    Lookup averaged 0.000162 seconds/record
    

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1118165]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others musing on the Monastery: (4)
As of 2024-04-23 15:19 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found