Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change

argument """ isn't numeric in numeric gt(>), error

by veerubiji (Sexton)
on Nov 02, 2011 at 09:35 UTC ( #935327=perlquestion: print w/replies, xml ) Need Help??
veerubiji has asked for the wisdom of the Perl Monks concerning the following question:

Hi I am running this code but I am getting error how to rectify this error

[% FOREACH st = university %] [%+ +%] [%+ st.location +%] [% FOREACH section = st.branch.electronics.section %] [% IF st.branch.electronics.section >1 %] branch student: [%+ +%] [%+ section.number +%] [% FOREACH sem = section.sem %] [%+ sem.semister +%] [%+ sem.subjects +%] [%+ sem.rank +%] [% END %] [% ELSE %] [%+ +%][%+ section.number +%] [%+ section.sem.semister +%][%+ section.sem.subjects +%] [%+ section.sem.rank +%] [% END %] [% END %] [% END %]

I am getting error like " argument"" isn't numeric in numeric gt(>)at input file handle line 44" this error at IF to eliminate this.

Replies are listed 'Best First'.
Re: argument """ isn't numeric in numeric gt(>), error
by Corion (Pope) on Nov 02, 2011 at 09:38 UTC

    You have been around for a long enough time to know that you can do more work to help us help you better.

    Please answer the following questions:

    1. Are you aware that the message is not an error but only a warning? See perllexwarn and perldiag.
    2. What is your input data?
    3. What is line 44?
    4. How does your input data correlate to line 44?
    5. What have you tried to rectify this?
Re: argument """ isn't numeric in numeric gt(>), error
by GrandFather (Sage) on Nov 02, 2011 at 09:44 UTC

    Wow! That's really odd. Normally it's line 42.

    True laziness is hard work
Re: argument """ isn't numeric in numeric gt(>), error
by JavaFan (Canon) on Nov 02, 2011 at 09:44 UTC
    That isn't Perl code.
      Indeed, you are an astute observer: it is Template Toolkit code, but it runs under Perl and its errors are Perl errors.


      A program should be light and agile, its subroutines connected like a string of pearls. The spirit and intent of the program should be retained throughout. There should be neither too little or too much, neither needless loops nor useless variables, neither lack of structure nor overwhelming rigidity." - The Tao of Programming, 4.1 - Geoffrey James

        Just because something is written in perl doesn't mean that perl is responsible for its errors, or that a perl forum is the right place to ask about them. There are dedicated mailing lists for Template Toolkit.

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://935327]
and the monks are mute...

How do I use this? | Other CB clients
Other Users?
Others exploiting the Monastery: (8)
As of 2018-03-17 16:54 GMT
Find Nodes?
    Voting Booth?
    When I think of a mole I think of:

    Results (224 votes). Check out past polls.