Hi all,
This is my first post here. I have benefited a lot from the information on this site and thank all you folks out there for your valuable and timely assistance.
I have been working with perl for 4 weeks now. I have written a script that performs data type validation. It takes in integers/decimals/dates and makes sure that they are within the boundaries of their data types. but now, if an integer field comes in with a special character ($ or #), perl still accepts it as a valid integer value. How can I ensure that if a variable that is defined as an integer comes in with special characters, it is rejected.
Hope I hear from one of you. Thanks..!!!
-
Are you posting in the right place? Check out Where do I post X? to know for sure.
-
Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
<code> <a> <b> <big>
<blockquote> <br /> <dd>
<dl> <dt> <em> <font>
<h1> <h2> <h3> <h4>
<h5> <h6> <hr /> <i>
<li> <nbsp> <ol> <p>
<small> <strike> <strong>
<sub> <sup> <table>
<td> <th> <tr> <tt>
<u> <ul>
-
Snippets of code should be wrapped in
<code> tags not
<pre> tags. In fact, <pre>
tags should generally be avoided. If they must
be used, extreme care should be
taken to ensure that their contents do not
have long lines (<70 chars), in order to prevent
horizontal scrolling (and possible janitor
intervention).
-
Want more info? How to link
or How to display code and escape characters
are good places to start.
|