Results 1 to 2 of 2

Thread: Basic Cube Question

  1. #1
    Join Date
    Mar 2010
    Posts
    3

    Exclamation Basic Cube Question

    Hi there,

    I am new to cubes so am wondering if I create and process a simple cube with a dimension called CUST_TYPE_DIM on the CUST_TYPE column using the following table and 5 rows then why when I query the cube do I get the attached counts? Surely the counts should be Internal = 3, External = 2?

    Code:
    create table CUSTOMER(
    CUST_ID int,
    CUST_NAME varchar(20),
    CUST_TYPE varchar(20))
    
    insert into CUSTOMER
    values(1,'Harry','Internal')
    insert into CUSTOMER
    values(2,'Barry','Internal')
    insert into CUSTOMER
    values(3,'Sally','External')
    insert into CUSTOMER
    values(4,'Larry','External')
    insert into CUSTOMER
    values(5,'Jerry','Internal')
    Thanks in advance.
    Attached Images Attached Images

  2. #2
    Join Date
    Mar 2010
    Posts
    3
    So it looks like the cube is summing (external is cust_id 3 + 4 = 7; internal is cust_id 1 + 2 + 5 = 8) the Cust_id field and not counting it. How do I remedy this so that I am getting a count of the number of customers of each type?

Tags for this Thread

Posting Permissions

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