Groups in tables or crosstabs

I have a table that lists fields from my database with their data and what category they're in.  Each category has a note attached to it.  I have a query that works fine combining these but I can't seem to get the note to show up for each category.  I used column groups, but it only adds one per page, not at the begining of every category.   Can this be done in a table? In theory it should look something like this:

|Category1 | Note1                    |

|Category1 | Field1 | Value1 |

|Category1 | Field2 | Value2 |

|Category2 | Note2                    |

|Category2 | Field1 | Value1 |

|Category2 | Field2 | Value2 |

 

I understand I can use crosstabs to do this, but I can't find a tutorial for working with crosstabs in this mannor.  All deal with totals and such.  That is much more complex than I need, I just need a simple example of something like this.  So how would I do this in a cross tab?  Can someone point me to an example?

cschnell's picture
295
Joined: Dec 12 2017 - 1:17pm
Last seen: 1 year 9 months ago

4 Answers:

Yes sure. as per your structure : 

|Category1 | Note1                    |

|Category1 | Field1 | Value1 |

|Category1 | Field2 | Value2 |

|Category2 | Note2                    |

|Category2 | Field1 | Value1 |

|Category2 | Field2 | Value2 |

 

 

As per your requirement, select Table component,

step 1 : create group on "Category",

step 2 : add columns category, Fieldname, valuename,

step 3 : select all columns - > right click -> group columns -> add textfield on grouped area.

Step 4 : add Category Or Note fieldname in the textfield expression.

 

Thats it.

Hope it will work.

 

Regards,

Miwa

miwagada's picture
253
Joined: Nov 23 2015 - 1:32am
Last seen: 4 years 4 months ago

Table can be used with such requirements. Use Groups in Table component.For total part, use Group Footer or Table footer for grand total.

miwagada's picture
253
Joined: Nov 23 2015 - 1:32am
Last seen: 4 years 4 months ago

Please elaborate, because as mentioned in my question, I tried using groups but it only put one of the notes per page.  I need it at the begining of  every new category.  There may be ten different categories per page hence 10 notes.  So is there a way to do this with groups in a normal table?

I'm also not using any sort of total, just listing the values which are normally strings.

cschnell's picture
295
Joined: Dec 12 2017 - 1:17pm
Last seen: 1 year 9 months ago

Ah, I missed created a group inside the Dataset!  Thanks for pointing me in the right direction.

cschnell's picture
295
Joined: Dec 12 2017 - 1:17pm
Last seen: 1 year 9 months ago
Feedback
randomness