Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Database & SysAdmin
  3. Database
  4. Cross-Tabulations with multiple tables

Cross-Tabulations with multiple tables

Scheduled Pinned Locked Moved Database
databasehelp
6 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • C Offline
    C Offline
    CodingLover
    wrote on last edited by
    #1

    Hi all, Is anyone of you know a better way to cross-tabulate within multiple tables. At the moment what I'm going is based on the table selections, select a hard-coded query, which seems lots of work. Because I've to think about all the possibilities.

    I appreciate your help all the time... CodingLover :)

    M C 2 Replies Last reply
    0
    • C CodingLover

      Hi all, Is anyone of you know a better way to cross-tabulate within multiple tables. At the moment what I'm going is based on the table selections, select a hard-coded query, which seems lots of work. Because I've to think about all the possibilities.

      I appreciate your help all the time... CodingLover :)

      M Offline
      M Offline
      Mycroft Holmes
      wrote on last edited by
      #2

      As I barely understood the question, it does need a lot of clarification - what is a cross tab, why are you joing multiple tables and your last sentence does not compute. I'll take a guess and recommend you look at using dynamic sql to build your query as a string and then execute it.

      Never underestimate the power of human stupidity RAH

      C 1 Reply Last reply
      0
      • C CodingLover

        Hi all, Is anyone of you know a better way to cross-tabulate within multiple tables. At the moment what I'm going is based on the table selections, select a hard-coded query, which seems lots of work. Because I've to think about all the possibilities.

        I appreciate your help all the time... CodingLover :)

        C Offline
        C Offline
        Chris Meech
        wrote on last edited by
        #3

        I'll hazard another guess at what you are looking for and suggest a search for pivot tables. :)

        Chris Meech I am Canadian. [heard in a local bar] In theory there is no difference between theory and practice. In practice there is. [Yogi Berra] posting about Crystal Reports here is like discussing gay marriage on a catholic church’s website.[Nishant Sivakumar]

        C 1 Reply Last reply
        0
        • M Mycroft Holmes

          As I barely understood the question, it does need a lot of clarification - what is a cross tab, why are you joing multiple tables and your last sentence does not compute. I'll take a guess and recommend you look at using dynamic sql to build your query as a string and then execute it.

          Never underestimate the power of human stupidity RAH

          C Offline
          C Offline
          CodingLover
          wrote on last edited by
          #4

          Thanks for the reply. Actually hard-coded sense I'm designing SQL queries dynamically. But the combination is huge. For example, say I've 2 tables and I wants to consider two columns, one from each. I can cross tabulate column_1 against column_2 or vise verse. So I'm confusing how to handle all the possibilities.

          I appreciate your help all the time... CodingLover :)

          M 1 Reply Last reply
          0
          • C Chris Meech

            I'll hazard another guess at what you are looking for and suggest a search for pivot tables. :)

            Chris Meech I am Canadian. [heard in a local bar] In theory there is no difference between theory and practice. In practice there is. [Yogi Berra] posting about Crystal Reports here is like discussing gay marriage on a catholic church’s website.[Nishant Sivakumar]

            C Offline
            C Offline
            CodingLover
            wrote on last edited by
            #5

            Thanks for the reply. I'll look at the pivot tables and let you know. If you could look at my previous post I really appreciate too.

            I appreciate your help all the time... CodingLover :)

            1 Reply Last reply
            0
            • C CodingLover

              Thanks for the reply. Actually hard-coded sense I'm designing SQL queries dynamically. But the combination is huge. For example, say I've 2 tables and I wants to consider two columns, one from each. I can cross tabulate column_1 against column_2 or vise verse. So I'm confusing how to handle all the possibilities.

              I appreciate your help all the time... CodingLover :)

              M Offline
              M Offline
              Mycroft Holmes
              wrote on last edited by
              #6

              This article[^] has helped a number of people, you need to do the thinking to apply the logic to your specific requirement. One of the beuties of CP is that there may be an article out there with, or close to your specific requirement which makes it dramatically easier to relate it to your problem.

              Never underestimate the power of human stupidity RAH

              1 Reply Last reply
              0
              Reply
              • Reply as topic
              Log in to reply
              • Oldest to Newest
              • Newest to Oldest
              • Most Votes


              • Login

              • Don't have an account? Register

              • Login or register to search.
              • First post
                Last post
              0
              • Categories
              • Recent
              • Tags
              • Popular
              • World
              • Users
              • Groups