SitePoint Sponsor

User Tag List

Results 1 to 3 of 3
  1. #1
    SitePoint Wizard boxhead's Avatar
    Join Date
    Feb 2004
    Location
    UK
    Posts
    1,040
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    multiple view or one big one.

    I have the following:

    t_division
    t_district
    t_area
    t_scheme

    every scheme belong to a area, which belongs to a district which belongs to a division.

    I am creating a view which shows all the areas, the number of schemes in that area, the district the area belongs to, the number of schemes in that district, the division the district belongs to and the number of schemes in the district.

    I currently have 3 views which do the counts for division, district and area and the 4th view pools it all together. Would it be better/worse to do away with the 3 additional views and do the counting in the main view?

    cheers

    monkey
    monkey - the rest is history

  2. #2
    SQL Consultant gold trophysilver trophybronze trophy
    r937's Avatar
    Join Date
    Jul 2002
    Location
    Toronto, Canada
    Posts
    39,017
    Mentioned
    53 Post(s)
    Tagged
    2 Thread(s)
    Quote Originally Posted by boxhead View Post
    Would it be better/worse to do away with the 3 additional views and do the counting in the main view?
    yes

    what happened when you tested it?
    r937.com | rudy.ca | Buy my SitePoint book: Simply SQL
    "giving out my real stuffs"

  3. #3
    SitePoint Guru
    Join Date
    Sep 2008
    Posts
    977
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    this link may help you as it did me.

    http://sqllessons.com/categories.html

    bazz


Bookmarks

Posting Permissions

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