Click here to get back home

Hash ref problem in Plucene::Simple (while searching a term)

 HomeNewsGroups | Search | About
 comp.lang.perl.misc    Post an article   get this group's latest topics as an RSS feed add this group's latest topics to your My MSN content add this group's latest topics to your My Yahoo content
Subject Author Date
Hash ref problem in Plucene::Simple (while searching a term) Edward Wijaya 11-06-2004
Get Chitika Premium
Posted by Edward Wijaya on November 6, 2004, 10:27 pm
Please log in for more thread options
>>
>> [snip]
>>
>> > if I print "$1\n",
>> > the file prints just fine. But, if I do something like print "$1 after
>> > \n", the whole output is messed up. If I print "before $1\n", nothing
>> > prints at all. If I print "before $1 after\n", only after prints.
>>
>> not really sure, but could be a rogue "\r" in $1,


> There
> is a rogue carriage return (0xd) in the string

> Is there something I can do to deal with this
> situation?


Repair the corrupted file:

perl -p -i -e 'tr/\r//d' bad_file


--
Tad McClellan SGML consulting
tadmc@augustmail.com Perl programming
Fort Worth, Texas

Similar ThreadsPosted
question about plucene October 31, 2004, 7:47 pm
PLucene minimum for indexing? November 2, 2006, 11:41 am
Term::ReadLine::GNU problem January 1, 2006, 11:57 am
Searching an example for a defined hash value of a nonexisting hash key July 20, 2004, 5:47 pm
PLUCENE equivalent module for Free Text Retrieval in DBMS November 1, 2004, 11:16 am
Searching within the hash values of an array of hashes August 26, 2007, 12:18 am
problem searching and replacing text file data April 23, 2006, 10:05 pm
YAHP - Ref to a hash via xml::simple prob. November 24, 2004, 4:54 pm
LWP::Simple getstore not working inside of hash :( January 3, 2005, 10:13 pm
simple hash of arrays, I cant see the trees for the forest August 23, 2006, 9:26 pm

Our other projects:

Art Dolls, Fairies and Mermaids - Sunnyfaces.net

Roy's Linux, Programming and Search Engines messages

1-Script XML SitemapXML Sitemap