Beefy Boxes and Bandwidth Generously Provided by pair Networks Bob
Perl Monk, Perl Meditation
 
PerlMonks  

How can I pass number of rows value in psql table into HTML?

by Anonymous Monk
on Mar 12, 2001 at 22:48 UTC ( #63893=perlquestion: print w/ replies, xml ) Need Help??
Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:

Comment on How can I pass number of rows value in psql table into HTML?
Re: How can I pass number of rows value in psql table into HTML?
by tye (Cardinal) on Mar 12, 2001 at 23:18 UTC
    Personally, I don't have a clue what you are talking about. Here are some suggestions:

    Get a login with this site you can better track your postings and people have more options on how to communicate with you.

    Read the site documentation.

    Post a much more clear question about this to Seekers of Perl Wisdom. It may not show up right away as content there is "moderated" but, since you will have followed my previous advice, you'll be able to find your question in your list of write ups and can set your user settings (both from your home node) to notify you when someone replies, even if your question is never "approved".

    I plan to delete this question (and my answer) when it appears that you've read my message (unless someone comes up with a better idea).

      questions looks clear as day to me. He has a psql table, and he's using perl probably for a cgi script. He wants to use the # of rows value inside his cgi script. But he doesn't know how to find this out. I'd like to know too.
Re: How can I pass number of rows value in psql table into HTML?
by arhuman (Vicar) on Mar 13, 2001 at 18:20 UTC
    If you mean getting the number of row in a table via a DBI access (guessing too) :
    A 'select * from yourtable' as a query
    and a fetchrow_array would return an array,
    you'll only have to count the number of item in this array
    (each item is column...)
Re: How can I pass number of rows value in psql table into HTML?
by psini (Deacon) on May 19, 2008 at 19:31 UTC

    SELECT count(*) FROM yourtable is much better: it is faster and avoid transferring to your program the contents of the entire table (with huge tables this can make a huge difference)

    This statement return only one row, with only one integer value, which is the number of rows in yourtable

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://63893]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others romping around the Monastery: (10)
As of 2014-04-23 23:14 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    April first is:







    Results (557 votes), past polls