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)
problem in designing report in birt
Jyoti Anand
<p>i want to use this data in the table to design a chart:</p><p> </p><p> </p><p>and i want to design a chart using birt like this:</p><p> </p><p> </p><p> </p><p> </p><p>how to do that .</p><p> </p><p>plese helpp>.....</p>
Find more posts tagged with
Comments
GLO_FR
<p>Hi,</p><p> </p><p>this is a simple stacked bar chart with 2 series (in your case).</p><p>If you can modify dataset a little your data to have it like this, I shouldn't be too difficult</p><pre class="_prettyXprint">Scanned Application | .Net | 306Cleared Application | .Net | 50Scanned Application | Java/J2EE | 127Cleared Application | Java/J2EE | 31...</pre><p>here an example</p>
Jyoti Anand
<p>
GLO_FR
<p>Hi Jyoti,</p><p> </p><p>Try this query, it should give you the expected output</p><pre class="_prettyXprint _lang-sql">SELECT 'SCANNED_APPLICATION' AS APP_TYPE, A.TECHNOLOGY AS APP_TECH, COUNT(A.PROJECTID) AS APP_COUNT FROM AIS.dbo.PROJECT_MASTER AWHERE MONTH(DATE) = 1AND SCAN LIKE '%Y%'GROUP BY TECHNOLOGYUNIONSELECT 'CLEARED_APPLICATION' AS APP_TYPE, A.TECHNOLOGY AS APP_TECH, COUNT(A.PROJECTID) AS APP_COUNT FROM AIS.dbo.PROJECT_MASTER AINNER JOIN AIS.dbo.PROJECT_SCAN_MASTER BON A.PROJECTID = B.PROJECTIDAND B.MONTH(SUBMITDATE) = 1AND B.CLEARED = 'YES'GROUP BY A.TECHNOLOGY</pre><p>You should get this result</p><pre class="_prettyXprint _lang-">APP_TYPE | APP_TECH | APP_COUNT
+
+
SCANNED_APPLICATION | .Net | 10SCANNED_APPLICATION | Java/J2EE | 3SCANNED_APPLICATION | PHP | 8CLEARED_APPLICATION | .Net | 6CLEARED_APPLICATION | Java/J2EE | 3CLEARED_APPLICATION | PHP | 4</pre>
Jyoti Anand
<p>IT WORKED....THANK YOUU SO SO VERY MUCHH..............THNKYOU</p>
GLO_FR
<p>You're welcome</p>
Jyoti Anand
<p>sir, i have another problem ,</p><p>i have these two tables:</p><p>and wht the problem is that i am getting a null value corresponding to the technology</p><p> </p><p>now if i change the SP.TECHNOLOGY to CP.TECHNOLOGY in the third line then i am getting the right output but only for a single case so how should i manipulate my query to get the right output.</p><p> </p><p> </p><p>hoping for a quick and positive response .</p><p> </p><p>thank you.</p>
GLO_FR
<p>Hi,</p><p> </p><p>this error is there because you're using a full outer join and the number of rows retuned by the differents queries is not the same.</p><p>Query n°1 (on SP.TECHNOLOGY) returns 3 technologies : Php, .Net, Java</p><p>Query n°2 (on CP.TECHNOLOGY) returns 4 technologies : Php, .net, Java, Asp</p><p> </p><p>With the full outer join, you're triing to create a link between those results BUT in the first case you're using the smaller list of technologies. What happens is that the database matches and returns the technology names when this one is present, otherwise it returns null.</p><p> </p><p>If you really want an output like this one it's saffer to do this </p><pre class="_prettyXprint _lang-sql">SELECT APP_TECH, SUM(SCANNED_APPLICATION) AS SCANNED_APPLICATION, SUM(CLEARED_APPLICATION) AS CLEARED_APPLICATIONFROM (SELECT A.TECHNOLOGY AS APP_TECH, 1 AS SCANNED_APPLICATION, 0 AS CLEARED_APPLICATION FROM AIS.dbo.PROJECT_MASTER A WHERE MONTH(DATE) = 1 AND SCAN LIKE '%Y%' UNION SELECT A.TECHNOLOGY AS APP_TECH, 0 AS SCANNED_APPLICATION, 1 AS CLEARED_APPLICATION FROM AIS.dbo.PROJECT_MASTER A INNER JOIN AIS.dbo.PROJECT_SCAN_MASTER B ON A.PROJECTID = B.PROJECTID AND B.MONTH(SUBMITDATE) = 1 AND B.CLEARED = 'YES') AGROUP BY APP_TECH </pre>
Jyoti Anand
<p>sir it is not returning the output as previous one.......</p><p> </p><p>the first table shows what u have posted the latest query n the second table shows the previous query....</p><p> </p><p>i have taken the month as '2'</p><p> </p><p>please helpp.....</p><p> </p><p> </p><p> </p><p> </p>
GLO_FR
<p>Hi,</p><p> </p><p>sorry for the late answer, I was quite busy this week.</p><p> </p><p>In fact, I don't understand exactly your needs.</p><p>What kind of output do you want ?</p><p>This one </p><pre class="_prettyXprint">APP_TYPE | APP_TECH | APP_COUNT
+
+
SCANNED_APPLICATION | .Net | 10SCANNED_APPLICATION | Java/J2EE | 3...</pre><p>or this one</p><pre class="_prettyXprint">SCANNED_APPLICATION | CLEARED_APPLICATION | TECHNOLOGY
+
+
10 | 4 | .Net 6 | 7 | Java/J2EE...</pre>
Jyoti Anand
<p>sir i need the table in the second format where "scanned_application","cleared_application"and "technology " are the column names...now i need the data in that format.</p>
GLO_FR
<p>Hi,</p><p> </p><p>this query should works</p><pre class="_prettyXprint _lang-sql">SELECT APP_TECH, SUM(SCANNED_APPLICATION) AS SCANNED_APPLICATION, SUM(CLEARED_APPLICATION) AS CLEARED_APPLICATIONFROM (SELECT A.TECHNOLOGY AS APP_TECH, 1 AS SCANNED_APPLICATION, 0 AS CLEARED_APPLICATION FROM AIS.dbo.PROJECT_MASTER A WHERE MONTH(DATE) = 1 AND SCAN LIKE '%Y%' UNION SELECT A.TECHNOLOGY AS APP_TECH, 0 AS SCANNED_APPLICATION, 1 AS CLEARED_APPLICATION FROM AIS.dbo.PROJECT_MASTER A INNER JOIN AIS.dbo.PROJECT_SCAN_MASTER B ON A.PROJECTID = B.PROJECTID AND B.MONTH(SUBMITDATE) = 1 AND B.CLEARED = 'YES') AGROUP BY APP_TECH </pre><p><span style="font-size:14px;">what is the output you have ?</span></p>