Well, assuming you print the name of the file that failed
to open in the error message, a simple grep on the file
name would find its declaration immediately - which got to
be faster than first going to the line number, and then
grepping for the variable name. (
vi +/filename/ program.pl)
Depending on your preference, you might be right about the
SQL query (I usually write modules with just a handful of
related queries in the same file, which would then be relatively
small, so there's hardly any searching needed). But I was
arguing against the sentiment one should always have to have
the line number in a die message. The fact that there are
cases where you might want to have the line numbers doesn't
dispute that.
Abigail
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Titles consisting of a single word are discouraged, and in most cases are disallowed outright.
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, details, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, summary, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
| |
For: |
|
Use: |
| & | | & |
| < | | < |
| > | | > |
| [ | | [ |
| ] | | ] |
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.