Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Search results for query: *

  1. KevinADC

    Matching Alternative Patterns slows down search tremendously!

    What version of perl and what operating system? There can be a very wide range of difference between versions and operating systems and the slowness you experience may not be typical of all perl users. ------------------------------------------ - Kevin, perl coder unexceptional! [wiggle]
  2. KevinADC

    What are most popular Perl forums?

    perlmonks.com devshed.com perlguru.com stackoverflow.com (not a "forum") unix.com has no dedicated perl forum but there is a "shell programming and scripting" forum and it is very busy but 99% of the questions are other than perl. ------------------------------------------ - Kevin, perl...
  3. KevinADC

    Use of $# to get array size in Perl 5.10

    This is definetly wrong: $#{@{$listref}} that's a double-layering of dereferencing and should have been: $#{$listref} I don't know why it would work in 5.8 with "strict" turned on. ------------------------------------------ - Kevin, perl coder unexceptional! [wiggle]
  4. KevinADC

    use module via variable ? can't get it to work

    Its not hard to do. I assume you didn't know the difference between "compile" and "run" times and the difference between "use" and "require". Now that you know you can load modules conditionally all you want. ------------------------------------------ - Kevin, perl coder unexceptional! [wiggle]
  5. KevinADC

    Need help to parse and summarize a log file

    Keep adding hash keys and counting what you need. What have you tried? ------------------------------------------ - Kevin, perl coder unexceptional! [wiggle]
  6. KevinADC

    use module via variable ? can't get it to work

    there is a pragma called "if" that allows you to conditionally load modules but I am not familiar with its usage. Might be new for perl 5.10 ------------------------------------------ - Kevin, perl coder unexceptional! [wiggle]
  7. KevinADC

    Need help to parse and summarize a log file

    use a hash where the dates are the hash keys and the value is the count. ------------------------------------------ - Kevin, perl coder unexceptional! [wiggle]
  8. KevinADC

    Appending then Reading

    Your code should be printing the first line of the file, not the last, either before or after appending new data to the file. ------------------------------------------ - Kevin, perl coder unexceptional! [wiggle]
  9. KevinADC

    Getting Started with Perl

    free perl IDE for Windows: www.perl-express.com don't bother with PWS, download and install apache: www.apache.org You can google for "apache setup tutorial" to get your CGI scripts running ------------------------------------------ - Kevin, perl coder unexceptional! [wiggle]
  10. KevinADC

    CGI + Perl issue

    Cool, thanks for the update and glad you got it working. ------------------------------------------ - Kevin, perl coder unexceptional! [wiggle]
  11. KevinADC

    use perl to generate index.html

    Assuming the perl script is in the cgi-bin, and the style-sheet is in the web root ( if it isn't you may have to move it there), you should make the path to the style sheet relative to the cgi-bin using ../ in the URI: <link rel=\"stylesheet\" type=\"text/css\" href=\"../style.css\">\n the...
  12. KevinADC

    Split Function

    The first argument to split() is a regexp, not a string. Even using single-quotes does not make it a string, so you have to escape special characters like ^. ------------------------------------------ - Kevin, perl coder unexceptional! [wiggle]
  13. KevinADC

    calling system command

    The Perl.pm file should go in a directory name Syntax/Highlight (Syntax::Highlight) relative to the directory where tekify.cgi is stored or you could add it to @INC with the lib pragma. Its pure perl so doesn't have to be installed, you can just upload the source code. tekify.cgi has the color...
  14. KevinADC

    calling system command

    Sorry, I renamed it tekify.txt so you can get the source code now. Rename it to .cgi or .pl if your server requires one of those extensions to execute a perl script. ------------------------------------------ - Kevin, perl coder unexceptional! [wiggle]
  15. KevinADC

    calling system command

    The perl to TGML convertor is an existing CPAN module that I modified to add TGML code and the links to perldoc and some other modifications I no longer remember. http://search.cpan.org/~johnsca/Syntax-Highlight-Perl-1.0/lib/Syntax/Highlight/Perl.pm The two scripts can be downloaded from...
  16. KevinADC

    Removing Trailing Spaces In Printf For A String

    hehehe..... thats funny. You tell printf to add spaces on the right if necessary to pad a string to ten places, but then you don't want the spaces! Try not using printf and just use print. ------------------------------------------ - Kevin, perl coder unexceptional! [wiggle]
  17. KevinADC

    create arrays from list

    this line: if (m#^(\d{1,2}/\d{1,2}/\d\d{2,4})#) { better written as: if (m#^(\d{1,2}/\d{1,2}/\d{2,4})#) { if the date is always in MM/DD/YYYY you could just use that pattern exclusively: if (m#^(\d\d/\d\d/\d\d\d\d#) { ------------------------------------------ - Kevin, perl coder...
  18. KevinADC

    create arrays from list

    Going by the very slim example of data, this is a barebones of a script you can expand on: use strict; use warnings; my %ReportHash; my $key; open(my $REPOPT ,'path/to/report/file') or die "$!"; while( <$REPORT>) { chomp; next if (/^\s*$/);#skip blank lines if...
  19. KevinADC

    How put 900,000,000 rows of data into mysql fast!!!

    900,000,000 In US(A) thats 900 million. Still a lot of whatever. ------------------------------------------ - Kevin, perl coder unexceptional! [wiggle]
  20. KevinADC

    calling system command

    mikrom, you're welcome to use this Perl to TGML converter if you want to: http://www.e-pixs.com/highlight/ ------------------------------------------ - Kevin, perl coder unexceptional! [wiggle]

Part and Inventory Search

Back
Top