Another silly SQL ASP page thing

Results 1 to 2 of 2

Thread: Another silly SQL ASP page thing

  1. #1
    Join Date
    Dec 1969

    Default Another silly SQL ASP page thing

    The problem with developing cool tools for the unwashed masses is they always want more.<BR><BR>I have a database with several thousand records in it. One of the fields is "division". Possible entries are div_a, div_b, and div_c. Is there a way to execute a single SQL Query on the database that returns the number of div_a records, div_b records, and div_c records? (I actually have abou 25 divisions in there is why I&#039;m asking).<BR><BR>Thanks

  2. #2
    New ASP Guest

    Default try this pls

    SELECT division, COUNT(division)<BR>FROM your_table<BR>GROUP BY division

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts