Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
PUBLIC CLOUD
PRIVATE CLOUD
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Intelligence (Analytics)
Table suppress duplicate with merge cells
lukasw44
Hello i create simple table and now i have got : <br />
<pre class='_prettyXprint _lang-auto _linenums:0'>
lp | code | nom | value |
1 | aaa | 12 | 132 |
| | 24 | 1234 |
| | 44 | 2222 |
</pre>
I am using suppress duplicate so i have got only 1 time aaa and 1 but i need to have got like that: <br />
<br />
<pre class='_prettyXprint _lang-auto _linenums:0'>
lp | code | nom | value |
1 | aaa | 12 | 132 |
| |
| | 24 | 1234 |
| |
| | 44 | 2222 |
</pre>
So when value duplicate so merge cells <br />
<br />
haw i can do this ??<br />
<br />
<br />
I also have got problem with suppress duplicate if i have got more than 1 groups ?<br />
<br />
for example : <br />
<pre class='_prettyXprint _lang-auto _linenums:0'>
lp | code | nom | value |
1 | aaa | 12 | 132 |
| | | 1234 |
| | | 2222 |
1 | aaa | 56 | 132 |
| | | 1234 |
| | | 2222 |
</pre>
<br />
<br />
<br />
but i need to have got : <br />
<pre class='_prettyXprint _lang-auto _linenums:0'>
lp | code | nom | value |
1 | aaa | 12 | 132 |
| | |
| | | 1234 |
| | |
| | | 2222 |
| |
| | 56 | 132 |
| | |
| | | 1234 |
| | | 23423 |
| | | 2222 |
</pre>
Find more posts tagged with
Comments
mwilliams
This appears to be just a table with 3 levels of grouping. Then, you'd use the drop feature to drop the group values to your detail row. You can set a cell's drop property by selecting the header cell and going to the property editor's general section.
keerthink
<p>Hi,<br>
Will dropping the group header to detail row <em>merge</em> the rows beneath it that I set <strong>Suppress Duplicates: true</strong> ? so it will look like this--</p>
<p> </p>
<p>Group header 1</p>
<p>Detail 1</p>
<p> </p>
<p>Detail 2</p>
<p>Detail 3</p>
<p>Detail 4</p>
<p>Group header 2 </p>
<p>Detail 1</p>
<p> </p>
<p>Detail 2</p>
<p>Detail 3</p>
<p>Detail 4</p>
<p> </p>
<p>and not like this--</p>
<p> </p>
<p>Group header 1</p>
<p>Detail 1</p>
<p> </p>
<p>Detail 2</p>
<p> </p>
<p>Detail 3</p>
<p> </p>
<p>Detail 4</p>
<p>Group header 2 </p>
<p>Detail 1</p>
<p> </p>
<p>Detail 2</p>
<p> </p>
<p>Detail 3</p>
<p> </p>
<p>Detail 4</p>
<p> </p>
<p>Thanks. </p>
keerthink
<p>Oops that did not come out right...please see the attachment.</p>
mwilliams
What's your BIRT version? I'll make you a sample that does what you're wanting.
keerthink
<p>RCP Designer 4.4.2 </p>
<p> </p>
<p>Thanks a lot.</p>
mwilliams
Here's a report with manual suppress duplicates that will handle your borders and visibility. I use no grouping in the table, but you could use grouping as well.<br><br>Take a look at:<ul class="bbc"><li>the onCreate of the table header: variables initialized</li><li>visibility property of data elements (property editor): variables checked to see if repeating values</li><li>onCreate of detail row table cells: script to set borders based on value changes</li></ul>Hope this helps.
keerthink
<p>Hello Michael,</p>
<p> </p>
<p>Thanks a lot for your example. This is exactly what I need my report to do. In my report, I have dropped the the header to the detail row. and I have suppressed duplicates in the first column so that my group header (the first cell of the detail row) appears just once if repeated. In this scenario,</p>
<p> </p>
<ul class="bbc"><li>the onCreate of the table header: variables initialized -- <span style="color:#0000ff;">Instead, can i just initialize my group header data element?</span></li>
<li>visibility property of data elements (property editor): variables checked to see if repeating values -- <span style="color:#0000ff;">Isn't this the same as 'Suppress Duplicates"?</span></li>
<li>onCreate of detail row table cells: script to set borders based on value changes -- <span style="color:#0000ff;">In my case, just the first cell of the detail row- i tried using your script to do just this step, but to no result.</span></li>
</ul><p style="margin:0px;">Please excuse my ignorance. </p>
<p style="margin:0px;"> </p>
<p style="margin:0px;">Thanks a lot for your help.</p>
mwilliams
Can you attach your design?
keerthink
<p><a data-ipb='nomediaparse' href='
https://www.dropbox.com/sh/3iflw9i2niv1bmx/AAAXeLDJe2rnkf6AKbe1wmVca?dl=0'>https://www.dropbox.com/sh/3iflw9i2niv1bmx/AAAXeLDJe2rnkf6AKbe1wmVca?dl=0</a></p>
;
<p> </p>
<p>Thanks</p>
keerthink
<p>Sorry I was wrong, I have the suppress duplicates on the first and second columns, but here, if more than 1 theme had the same score (e.g score 6), it will hide that score from all the remaining themes. That is an issue.</p>
mwilliams
I'm confused with what you're meaning. With the data and report you attached, what would you like to see? Just the first two columns suppressed within the Theme group? Let me know.
keerthink
<p>Yes.</p>
<p>I would like to see the the rows grouped by first column which is the '<em>theme</em>'.</p>
<p>The second column has scores for each theme. But these scores should only be visible once per <em>theme</em>, but I cannot suppress it because they wont be unique values(more than one theme can have the same score)</p>
<p>for e.g If you run my report design, the 4th theme does not show a score because it got removed since it was the same as above (i.e "6") </p>
<p>And while this happens, I would love it if the hidden data cells don't show the border.(or looks merged)</p>
<p> </p>
<p>Again,</p>
<p>Thank you!!</p>
mwilliams
Take a look at this report. I removed the "suppress duplicates" setting that you had and did the suppressing manually. I also changed how you did your borders on your table to not duplicate them so I could easily remove the border when you don't want it. Visibility script on the theme data elements and in the onCreate of the table header and theme cells do the rest.
keerthink
<p>Works like a charm! Thank you very much!!!</p>
<p>Btw, I had uploaded one file and was referring to another in my posts. Sorry for the confusion.</p>
<p>Thanks again.</p>
<p> </p>
<p>PS: Is it possible to remove the attachment from your post? </p>
mwilliams
You'd like me to remove the attachment (your design) from my post? Sure. I can do that. Just let me know.<br><br>I'll just replace it with an example using the sample database.
keerthink
<p>Yes please. That would be great.</p>
Sekhar Bullet
<p>HI Williams,</p>
<p> </p>
<p>I have followed the same as you said above:</p>
<ul class="bbc"><li>the onCreate of the table header: variables initialized</li>
<li>visibility property of data elements (property editor): variables checked to see if repeating values</li>
<li>onCreate of detail row table cells: script to set borders based on value changes</li>
</ul><p style="margin:0px;">but if a value comes next row it's hidden even though it's checking with other columns ,</p>
<p style="margin:0px;"> </p>
<p style="margin:0px;">Please see the attachment<img src="
http://Desktop\Screenshot.jpg"
; alt="Desktop%5CScreenshot.jpg"></p>
vijayshankar245
<blockquote class="ipsBlockquote" data-author="mwilliams" data-cid="135628" data-time="1429639045">
<div>
<p>Take a look at this report. I removed the "suppress duplicates" setting that you had and did the suppressing manually. I also changed how you did your borders on your table to not duplicate them so I could easily remove the border when you don't want it. Visibility script on the theme data elements and in the onCreate of the table header and theme cells do the rest.</p>
</div>
</blockquote>
<p>Hi mwilliams</p>
<p> </p>
<p>The above solution you have provided to suppress the duplicates works well with pdf and webviewer output. But i want the same to be done for excel output where in with excel as output format the background color none doesn't work and the cells are not merged.</p>
<p> </p>
<p>Kindly help if you know the solution for this.</p>