Grouping multiple values on Details section
I have got an output from SQL query:
ID Value
1 1
1 3
1 5
1 7
1 9
2 1
2 4
3 1
3 2
3 3
I just want to have on each page ID and whole list of values assigned to this id. On next page I should have next ID a it's values.
As you can see for ID 1 I have got 4 values, for 2 I have got only 2 values, for 3 I have got 3 values. I want to say that how many values I have got for particular ID can be different.
I don't know what is the name of this kind go grouping, If someone will name it I will be able to dig the Internet to find the solution.
If someone knew how to do this and will share the knowledge I will really appreciate this.
Best regards,
Volcano
You should add a group (Insert Group) for ID and put Value in the detail section. Make sure to start each group on a new page (Section Expert for your group header or footer, then tick New Page Before / After.
Related
Hi Everybody and thanks in advance to whom will answer my question:
I think I need a for loop in tableau and looking for a working around;
my table has the following structure
id, id_detail, result
1 1 fail
1 2 pass
1 3 pass
2 1 pass
2 2 pass
3 1 fail
3 2 pass
...
...
I need to assign to id=1 fail; id=2 pass; id=3 fail
do You have any suggestions?
You may use the alphabetic order where pass is greater than fail
create this calculated field
{FIXED [Product ID]: MIN([Test Evaluation])}
and you'll get what you want
My first question, so please excuse any mistakes.
We have internal ID numbers for product that we are selling, composed of: [SalesOrder_Num]/[Num].
For each Id No. we offer a Test Certificate to the client. Test Certificate defines the suitable age of product, along with its technical specification. Multiple items (20-30) on sales order can have same technical specification, but different ID number. ID Number also becomes Certificate Number.
We need to print/pdf these test certificates using Crystal Reports. There is a custom made Certificate Window on which technical specs are manually typed, along with sales order number. We also fill in number of Certificates (= [Num]).
What we now want is: Print [Num] of records/PDF with Certificate Number incrementally increasing on each PDF - [SalesOrder_Num]/1, [SalesOrder_Num]/2, ... ... ,[SalesOrder_Num]/[Num-1], [SalesOrder_Num]/[Num].
How is it possible?
Best Regards,
K
Create a REPEATER table with a single column (How_Many) that looks like this:
How_Many
1
2
3
4
5
6
etc..
Now, in your report, add the Repeater Table and add a join condition of:
Order.quantity >= Repeater.How_Many
If the ">=" join option is not available, remove the join to the REPEATER table and create this condition in the Record Selection condition:
{Order.quantity} >= {Repeater.How_Many}
This would cause each order to be duplicated as many times as the value of {Order.quantity}.
If you are restricted to using an equal join, you can also modify the repeater table to include N records for each quantity N:
1
2
2
3
3
3
...
This would cause each order to be duplicated as many times as the value of {Order.quantity}.
If you need to print "N of M" modify the repeater table to look like this:
N M
1 1
2 1
2 2
3 1
3 2
3 3
and use an equal join to the N column.
An alternative solution is to use a 3rd-party Crystal tool. At least one of the 3rd-party Crystal Reports viewers listed here provides the functionality you are seeking (without needing to add a Repeater table to your database).
I have a dataset in MsAccess:
Fact Table - ChartReview:
ID EmployeeFK CategoryFK ObjectiveFK YesNoFK
1 22 1 1 0
2 11 1 2 1
3 11 2 3 1
4 22 3 6 2
5 22 2 5 0
6 22 2 4 1
Dimension Tables -
3_Employee:
ID EmployeeName
11 James Smith
22 John Doe
4_YesNo:
ID DescriptionYesNo
0 N/A
1 Yes
2 No
1_Category:
ID DescriptionCategory
1 Orientation
2 Individual
3 Progress
2_Objective:
ID CategoryFK DescriptionObjective
1 1 Object1
2 1 Object2
3 2 Object345
4 2 Object556
5 2 Object666
6 3 ObjectLast
Here is the Relations Model (colored dots show the appropriate relation):
My goal is to create a Form or (Form + SubForm)- where user will add data as following -
User will select the EmployeeName, and then - will proceed with the Category selection.
Then - will enter the Objective values (Yes, No or N/A) according to each Category associated with its Objective.
I created the Main Form (data source - ChartReview table):
and the Sub Form (data source - dimensions - Category, Objective tables):
But - my problem - I don't know how to connect MainForm + SubForm...
(so the user would enter data into Main, and then would be transferred to a Sub and will enter Yes/No/N/A for each Objective)
Also, I need my Yes/No/N/A values would be bound to each Objective, while now, unfortunately they're bound to only the 1st Objective...
And the last, I am not even sure the user will actually be able to fill out my SubForm, as it's created out of the Dimensions.
When I tried to enter or to change the info in the SubForm - the following error appears:
Any advice or suggestions - welcome !!!
Open the form in design view.
Click on the subform to select it.
If you can't see the properties pane, Right click on the subform and choose properties.
On the data tab there are the fields that you need to fill in.
Link Master Fields and Link Child Fields.
To start, put 3_Employee.ID in the "link Master fields" box
and ChartReview.EmployeeFK in the "Link Child Fields" box.
Manually enter valid data to test that the employee record works, then add the other links once this works.
I need to display row number sequence of each group.
I have used $V{PAGE_COUNT} and evaluation time as now
The report data that I am getting is
Group A
1.
2
3
4
...........
page ends ......
Group A
1
2
3
4
page ends ---------
Group B
1
2
3
4
5
page ends....
But my requirement is
Group A
1.
2
3
4
...........
page ends
Group A
5
6
7
8
9
page ends .......
Group B
1
2
3
4
5
page ends....
I need all rows of same group to be continuous sequence. And start sequence from 1 when group is changed
You should use the GroupName_COUNT variable in this case.
The quote from the JasperReports Ultimate Guide
When declaring a report group, the engine automatically creates a count variable that
calculates the number of records that make up the current group (that is, the number of
records processed between group ruptures).
The name of this variable is derived from the name of the group it corresponds to,
suffixed with the _COUNT sequence. It can be used like any other report variable, in any
report expression, even in the current group expression, as shown in the BreakGroup
group of the /demo/samples/jasper sample)
More info is here: Data Grouping
i'm having the table like
category_id category_name parent_id
1 General Grocery 0
2 Ready to eat 0
3 rice 1
4 oils 1
5 flour 1
6 seed 1
7 testing cate 0
8 testing 5
i want to display the categories with "n" number of sub categories in subcategories. My main moto is by using the array generated by the code i want to display in view page and the select menu in the zend form. I found the code in php. but i'm unable to use that in zend. Can some one help me out with this please.
Thank you.
I think you need to generate a tree.. so there are two known patterens to me
adjacency level pattern
Nested Level Patteren
I suggest you to use Nexted level pattern
If you follow the given below two links you will surely come to know what to do.
http://blog.richardknop.com/2009/05/nested-set-model/
http://baobab.sideralis.org/
By this you can generate appropriate tree. now you have to generate a tree in which you can select your items. so you should use this tree http://www.dhtmlx.com/docs/products/dhtmlxTree/index.shtml
you can keep checkboxes to select the items and store in the database