Jump to content
We've recently updated our Privacy Statement, available here ×

ktalarico

Members
  • Posts

    77
  • Joined

  • Last visited

  • Days Won

    1

 Content Type 

Profiles

Forum

Events

Featured Visualizations

Knowledge Base

Documentation (PDF Downloads)

Blog

Documentation (Test Area)

Documentation

Dr. Jaspersoft Webinar Series

Downloads

Everything posted by ktalarico

  1. I wrote a how to article about this: http://community.jaspersoft.com/wiki/how-override-default-tooltip-date-input-controls
  2. By default, the tooltip that is displayed for date input controls reads: "<Parameter Label>. If your parameter supports relative date expressions, you can enter expressions like 'WEEK+1' in this input control." This applies to input controls of type Date, Date/Time and Time. If you want to change the default text for ALL date input controls, you can modify the value of DATE_IC_TOOLTIP in WEB-INF/bundles/jasperserver_messages.properties. However if you want the tooltip to match the input controls' description, you can modify three entries in WEB-INF/jsp/modules/inputControls/InputControlTemplates.jsp as follows: <script id="singleValueDate" type="template/mustache"> <div id="{{id}}" class="leaf"> <label class="control picker" title="{{description}}"> <span class="wrap">{{#mandatory}}* {{/mandatory}}{{label}}</span> <input class="date" type="text" value="" {{#readOnly}}disabled{{/readOnly}} /> <div class="warning">{{message}}</div> </label> </div> </script> <script id="singleValueDatetime" type="template/mustache"> <div id="{{id}}" class="leaf"> <label class="control picker" title="{{description}}"> <span class="wrap">{{#mandatory}}* {{/mandatory}}{{label}}</span> <input class="date" type="text" value="" {{#readOnly}}disabled{{/readOnly}} /> <div class="warning">{{message}}</div> </label> </div> </script> <script id="singleValueTime" type="template/mustache"> <div id="{{id}}" class="leaf"> <label class="control picker" title="{{description}}"> <span class="wrap">{{#mandatory}}* {{/mandatory}}{{label}}</span> <input class="date" type="text" value="" {{#readOnly}}disabled{{/readOnly}} /> <div class="warning">{{message}}</div> </label> </div> </script>
  3. I think you want net.sf.jasperreports.export.{format}.exclude.key.{suffix} See http://jasperreports.sourceforge.net/config.reference.html#net.sf.jasperreports.export.{format}.exclude.key.{suffix}
  4. Our clients are seeing this problem (see picture). I am unable to reproduce it on our systems using Firefox, Chrome or IE. Wondering if anyone else has seen the problem.
  5. Hmmm, when I uploaded to the server, I did not get null. It only happens when I run directly from iReport/JasperSoft Studio.
  6. I have a row group called question with a bucket expression equal to $F{question} + $F{sort_order}. I only want to display the text of $F{question}, not $F{sort_order}; so I created a measure called questionmeasure with a value expression equal to $F{question}. In questionheader, I used questionmeasure in the textfield expression. It is displaying null. Basically, I want to use a measure expression where I would normally use a row group expression. Below is jrxml: <?xml version="1.0" encoding="UTF-8"?><jasperReportxmlns="http://jasperreports.sourceforge.net/jasperreports"xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"xsi:schemaLocation="http://jasperreports.sourceforge.net/jasperreportshttp://jasperreports.sourceforge.net/xsd/jasperreport.xsd"name="QuestionnaireResponseSummary" language="groovy" pageWidth="1350"pageHeight="1000" whenNoDataType="NoDataSection" columnWidth="1310"leftMargin="20" rightMargin="20" topMargin="20" bottomMargin="20"isIgnorePagination="true"> <property name="ireport.zoom" value="1.0"/> <property name="ireport.x" value="0"/> <property name="ireport.y" value="0"/> <property name="net.sf.jasperreports.export.xls.detect.cell.type" value="true"/> <style name="Crosstab Data Text" hAlign="Center"/> <parameter name="START DATE" class="java.util.Date"> <defaultValueExpression><![CDATA[new Date()]]></defaultValueExpression> </parameter> <parameter name="END DATE" class="java.util.Date"> <defaultValueExpression><![CDATA[new Date()]]></defaultValueExpression> </parameter> <parameter name="KIOSK GROUP" class="java.util.List"> <property name="parameter_type" value="multiselect"/> <property name="query" value="select distinct name from (selectkg.name from kiosk_group kg union select string_value fromsrv_instance_context_variable_map where property='kioskGroup')t where name not ilike'ZZ%'order by name"/> <defaultValueExpression><![CDATA[java.util.Arrays.asList(new String[" "])]]></defaultValueExpression> </parameter> <parameter name="QUESTIONNAIRE NAME" class="java.lang.String"> <property name="parameter_type" value="select"/> <property name="query" value="select distinct sd.display_name asdisplayName from srv_survey_definition sd where sd.active = true orderby sd.display_name"/> <parameterDescription><![CDATA[]]></parameterDescription> <defaultValueExpression><![CDATA[]]></defaultValueExpression> </parameter> <queryString> <![CDATA[with recursive survey_items(sort_order,kioskgroup,response_id,item_id,item_subclass,question)as ( select ARRAY[nde.page_indx,itm.survey_item_indx] as sort_order, sicm.string_value, resp.id, itm.id, itm.subclass, sltm.language_map_element::text as question from srv_survey_item itm join srv_transition_node nde on nde.id = itm.page_id join srv_survey_definition sd on sd.id = nde.survey_definition_id join srv_survey_response resp on resp.active_survey_definition_id = sd.id and resp.start_survey_date is not null join srv_survey_instance ssi on (ssi.survey_response_id = resp.id ) join srv_instance_context_variable_map sicm on (sicm.survey_instance_id = ssi.id and sicm.property like 'kioskGroup') join srv_language_text slt on slt.id = itm.main_text join srv_language_text_language_map sltm on sltm.srv_language_text_id = slt.id where itm.subclass <> 'DESCRIPTIVE_TEXT' and resp.start_survey_date between to_timestamp($P{STARTDATE},'YYYY-MM-DD') and (to_timestamp($P{END DATE}, 'YYYY-MM-DD') +interval '1 day' ) and resp.start_survey_date is not null and split_part(sd.survey_name,'_OUTDATED',1) IN (select survey_namefrom srv_survey_definition def where def.display_name = $P{QUESTIONNAIRENAME}) and $X{IN, sicm.string_value,KIOSK GROUP} and sicm.string_value not ilike 'ZZ%' and resp.id not in( select ssr.id from srv_survey_response ssr join srv_survey_instance si1 on ssr.id = si1.survey_response_id where (si1.exit_type is null and ssr.completed =false)) union select sort_order || coalesce(itm.survey_item_indx,0) || coalesce(itm.group_idx,0) || coalesce(itm.group_question_idx,0), si.kioskgroup, si.response_id, itm.id, itm.subclass, question || E'n' || sltm.language_map_element::text from srv_survey_item itm join survey_items si on itm.item_group_id = si.item_id or itm.question_group_id = si.item_id join srv_language_text slt on slt.id = itm.main_text join srv_language_text_language_map sltm on sltm.srv_language_text_id = slt.id),survey_responses as(selectsi.sort_order,si.kioskgroup,si.response_id,si.item_id,si.item_subclass,si.question,case when si.item_subclass='QUESTION_MULTIPLE_CHOICE' then sltm.language_map_element when si.item_subclass='QUESTION_MATRIX' then sltm.language_map_element || ' : ' || sltm2.language_map_element when si.item_subclass in ('QUESTION_TEXT','QUESTION_DATE') then 'n/a' end as choice,CASE when si.item_subclass='QUESTION_MULTIPLE_CHOICE' then (select count(*) from srv_survey_answer ans join srv_multiple_choice_answer_choice_join mChoice on ans.id = mChoice.matrix_part_answer_id where ans.question = si.item_id and mChoice.choice_id=slt.id and ans.response_id=si.response_id) when si.item_subclass='QUESTION_MATRIX' then (select count(*) from srv_survey_answer ans join srv_survey_answer_part_answers pa on pa.srv_survey_answer_id = ans.id join srv_survey_answer partans on pa.part_answers_id = partans.id join srv_multiple_choice_answer_choice_join mChoice on partans.id = mChoice.matrix_part_answer_id where ans.question = si.item_id and mChoice.choice_id=slt2.id andpartans.matrix_part=slt.id and ans.response_id=si.response_id) when si.item_subclass = 'QUESTION_TEXT' then (select count(*) from srv_survey_answer ans where ans.question = si.item_id and ans.response_id = si.response_id and ans.value is not null and ans.value <> '') when si.item_subclass = 'QUESTION_DATE' then (select count(*) from srv_survey_answer ans where ans.question = si.item_id and ans.response_id = si.response_id and ans.date_value is not null) end as num_chosen,slt.choice_indx as multiple_choice_sort,slt.part_indx as matrix_part_sort,slt2.choice_indx as matrix_choice_sort from survey_items sileft join srv_language_text slt onCASE when si.item_subclass='QUESTION_MULTIPLE_CHOICE' then slt.multiple_choice_question_id = si.item_id when si.item_subclass='QUESTION_MATRIX' then slt.matrix_question_id = si.item_id endleft join srv_language_text_language_map sltm on sltm.srv_language_text_id = slt.id--This extra join is so we can combine each matrix part with each choiceleft join srv_language_text slt2 on slt.matrix_question_id = slt2.multiple_choice_question_idleft join srv_language_text_language_map sltm2 on slt2.id = sltm2.srv_language_text_idwhere si.item_subclass not in ('SURVEY_ITEM_GROUP','QUESTION_GROUP')order by sort_order, multiple_choice_sort, matrix_part_sort, matrix_choice_sort)selectsort_order,multiple_choice_sort,matrix_part_sort,matrix_choice_sort,question,choice,kioskgroup,count (distinct response_id) as num_responses,sum(num_chosen) as num_chosenfrom survey_responsesgroup by sort_order, multiple_choice_sort, matrix_part_sort, matrix_choice_sort, kioskgroup, question, choiceorder by sort_order, multiple_choice_sort, matrix_part_sort, matrix_choice_sort, kioskgroup]]> </queryString> <field name="sort_order" class="java.sql.Array"/> <field name="multiple_choice_sort" class="java.lang.Integer"/> <field name="matrix_part_sort" class="java.lang.Integer"/> <field name="matrix_choice_sort" class="java.lang.Integer"/> <field name="question" class="java.lang.String"/> <field name="choice" class="java.lang.String"/> <field name="kioskgroup" class="java.lang.String"/> <field name="num_responses" class="java.lang.Long"/> <field name="num_chosen" class="java.math.BigDecimal"/> <variable name="PercentAnswered" class="java.lang.Double"> <variableExpression><![CDATA[$F{num_chosen} == 0 ||$F{num_responses} == 0 ? 0 :($F{num_chosen}/$F{num_responses})]]></variableExpression> </variable> <background> <band splitType="Stretch"/> </background> <title> <band height="82"> <staticText> <reportElement x="0" y="0" width="1276" height="36"/> <textElement textAlignment="Left" verticalAlignment="Middle"> <font size="24" isBold="true"/> </textElement> <text><![CDATA[Questionnaire Response Summary]]></text> </staticText> <textField isStretchWithOverflow="true" pattern="" isBlankWhenNull="true"> <reportElement x="0" y="36" width="1276" height="21"/> <textElement textAlignment="Left" verticalAlignment="Middle"> <font size="12"/> </textElement> <textFieldExpression class="java.lang.String"><![CDATA["Date: "+ new SimpleDateFormat("MM/dd/yyyy").format($P{START DATE}) + " to " +new SimpleDateFormat("MM/dd/yyyy").format($P{ENDDATE})]]></textFieldExpression> </textField> <textField isStretchWithOverflow="true" pattern="" isBlankWhenNull="true"> <reportElement x="0" y="57" width="1260" height="25"/> <box leftPadding="0" bottomPadding="2"/> <textElement verticalAlignment="Middle"> <font size="12"/> </textElement> <textFieldExpressionclass="java.lang.String"><![CDATA["Questionnaire Name:"+$P{QUESTIONNAIRE NAME}]]></textFieldExpression> </textField> </band> </title> <pageFooter> <band height="20"> <textField pattern="MM/dd/yyyy h.mm a" isBlankWhenNull="true"> <reportElement x="0" y="0" width="1276" height="20"/> <textElement verticalAlignment="Middle"> <font size="10"/> </textElement> <textFieldExpression class="java.lang.String"><![CDATA[newSimpleDateFormat("MM/dd/yyyy h:mm a").format(newjava.util.Date())]]></textFieldExpression> </textField> </band> </pageFooter> <summary> <band height="320" splitType="Stretch"> <staticText> <reportElement positionType="Float" mode="Transparent" x="0" y="97"width="1276" height="223" backcolor="#FFFFCC"/> <textElement> <font size="10"/> </textElement> <text><![CDATA[Report Overview: Provides _______. Reportexcludes all kiosk groups that start with 'ZZ' or 'zz' .Parameters: Start Date, End Date, Kiosk Group, Questionnaire Name.Data DefinitionsKiosk Group: Kiosk group selected in parameters.Questionnaire Name: Name of questionnaire selected in parameters.Question:Answer:Number Chosen out of Total Number of Responses:%Answered:]]></text> </staticText> <crosstab> <reportElement x="0" y="0" width="1310" height="320"/> <crosstabDataset isDataPreSorted="true"/> <rowGroup name="question" width="70"> <bucket> <bucketExpressionclass="java.lang.String"><![CDATA[$F{question} +$F{sort_order}]]></bucketExpression> </bucket> <crosstabRowHeader> <cellContents backcolor="#F0F8FF" mode="Opaque"> <box> <pen lineWidth="0.5" lineStyle="Solid" lineColor="#000000"/> </box> <textField isStretchWithOverflow="true"> <reportElement style="Crosstab Data Text"stretchType="RelativeToTallestObject" x="0" y="0" width="70"height="25"/> <textElement/> <textFieldExpressionclass="java.lang.String"><![CDATA[$V{questionmeasure}]]></textFieldExpression> </textField> </cellContents> </crosstabRowHeader> <crosstabTotalRowHeader> <cellContents/> </crosstabTotalRowHeader> </rowGroup> <rowGroup name="choice" width="100"> <bucket> <bucketExpression class="java.lang.String"><![CDATA[$F{choice}]]></bucketExpression> </bucket> <crosstabRowHeader> <cellContents> <textField> <reportElement style="Crosstab Data Text" x="0" y="0" width="100" height="25"/> <textElement/> <textFieldExpressionclass="java.lang.String"><![CDATA[$V{choice}]]></textFieldExpression> </textField> </cellContents> </crosstabRowHeader> <crosstabTotalRowHeader> <cellContents/> </crosstabTotalRowHeader> </rowGroup> <columnGroup name="kioskgroup" height="30" totalPosition="End"> <bucket> <bucketExpressionclass="java.lang.String"><![CDATA[$F{kioskgroup}]]></bucketExpression> </bucket> <crosstabColumnHeader> <cellContents backcolor="#F0F8FF" mode="Opaque"> <box> <pen lineWidth="0.5" lineStyle="Solid" lineColor="#000000"/> </box> <textField> <reportElement style="Crosstab Data Text" x="0" y="0" width="50" height="30"/> <textElement/> <textFieldExpressionclass="java.lang.String"><![CDATA[$V{kioskgroup}]]></textFieldExpression> </textField> </cellContents> </crosstabColumnHeader> <crosstabTotalColumnHeader> <cellContents backcolor="#BFE1FF" mode="Opaque"> <box> <pen lineWidth="0.5" lineStyle="Solid" lineColor="#000000"/> </box> <staticText> <reportElement x="0" y="0" width="50" height="30"/> <textElement textAlignment="Center" verticalAlignment="Middle"/> <text><![CDATA[Total kioskgroup]]></text> </staticText> </cellContents> </crosstabTotalColumnHeader> </columnGroup> <measure name="num_chosenMeasure" class="java.math.BigDecimal" calculation="Sum"> <measureExpression><![CDATA[$F{num_chosen}]]></measureExpression> </measure> <measure name="questionmeasure" class="java.lang.String"> <measureExpression><![CDATA[$F{question}]]></measureExpression> </measure> <crosstabCell width="50" height="25"> <cellContents> <box> <pen lineWidth="0.5" lineStyle="Solid" lineColor="#000000"/> </box> <textField> <reportElement style="Crosstab Data Text" x="0" y="0" width="50" height="25"/> <textElement/> <textFieldExpressionclass="java.math.BigDecimal"><![CDATA[$V{num_chosenMeasure}]]></textFieldExpression> </textField> </cellContents> </crosstabCell> <crosstabCell height="25" rowTotalGroup="question"> <cellContents backcolor="#BFE1FF" mode="Opaque"> <box> <pen lineWidth="0.5" lineStyle="Solid" lineColor="#000000"/> </box> <textField> <reportElement style="Crosstab Data Text" x="0" y="0" width="50" height="25"/> <textElement/> <textFieldExpressionclass="java.math.BigDecimal"><![CDATA[$V{num_chosenMeasure}]]></textFieldExpression> </textField> </cellContents> </crosstabCell> <crosstabCell width="50" columnTotalGroup="kioskgroup"> <cellContents backcolor="#BFE1FF" mode="Opaque"> <box> <pen lineWidth="0.5" lineStyle="Solid" lineColor="#000000"/> </box> <textField> <reportElement style="Crosstab Data Text" x="0" y="0" width="50" height="25"/> <textElement/> <textFieldExpressionclass="java.math.BigDecimal"><![CDATA[$V{num_chosenMeasure}]]></textFieldExpression> </textField> </cellContents> </crosstabCell> <crosstabCell rowTotalGroup="question" columnTotalGroup="kioskgroup"> <cellContents backcolor="#BFE1FF" mode="Opaque"> <box> <pen lineWidth="0.5" lineStyle="Solid" lineColor="#000000"/> </box> <textField> <reportElement style="Crosstab Data Text" x="0" y="0" width="50" height="25"/> <textElement/> <textFieldExpressionclass="java.math.BigDecimal"><![CDATA[$V{num_chosenMeasure}]]></textFieldExpression> </textField> </cellContents> </crosstabCell> <crosstabCell rowTotalGroup="choice"> <cellContents/> </crosstabCell> <crosstabCell rowTotalGroup="choice" columnTotalGroup="kioskgroup"> <cellContents/> </crosstabCell> </crosstab> </band> </summary> <noData> <band height="406"> <staticText> <reportElement x="0" y="136" width="1276" height="20"/> <box> <topPen lineWidth="1.0"/> <leftPen lineWidth="1.0"/> <bottomPen lineWidth="1.0"/> <rightPen lineWidth="1.0"/> </box> <textElement textAlignment="Center" verticalAlignment="Middle"> <font size="12" isBold="false"/> </textElement> <text><![CDATA[No Records Found]]></text> </staticText> <staticText> <reportElement x="0" y="10" width="1276" height="36"/> <textElement textAlignment="Left" verticalAlignment="Middle"> <font size="24" isBold="true"/> </textElement> <text><![CDATA[Questionnaire Response Summary]]></text> </staticText> <textField isStretchWithOverflow="true" pattern="" isBlankWhenNull="true"> <reportElement x="0" y="46" width="1276" height="20"/> <textElement textAlignment="Left" verticalAlignment="Middle"> <font size="12"/> </textElement> <textFieldExpression class="java.lang.String"><![CDATA["Date: "+ new SimpleDateFormat("MM/dd/yyyy").format($P{START DATE}) + " to " +new SimpleDateFormat("MM/dd/yyyy").format($P{ENDDATE})]]></textFieldExpression> </textField> <staticText> <reportElement positionType="Float" mode="Transparent" x="0" y="156"width="1276" height="230" backcolor="#FFFFCC"/> <textElement> <font size="10"/> </textElement> <text><![CDATA[Report Overview: Provides metrics on initiatedand completed questionnaires. Report excludes all kiosk groups thatstart with 'ZZ' or 'zz'.Parameters: Start Date, End Date, Kiosk Group, Questionnaire Name, Length of Time.Data DefinitionsKiosk Group: Kiosk group selected in parameters.Questionnaire Name: Name of questionnaire selected in parameters.Questionnaires Started: Number of times questionnaire is started.PatientsStarted: For sign-in survey, number of unique patients who started atleast one questionnaire. For non-sign-in and anonymous survey, number oftimes questionnaire is started.Questionnaires Completed: Number of times Questionnaire is completed.PatientsCompleted: For sign-in survey, number of unique patients who completedat least one questionnaire. For non-sign-in and anonymous survey, numberof times questionnaire is completed.% Completed Questionnaires: Number of completed questionnaires divided by started questionnaires.CompletedQuestionnaires Average Time: For completed questionnaires, total timespent on questionnaires divided by number of completed questionnaires.AbandonedQuestionnaires Average Time: For questionnaires started but notcompleted, total time spent on questionnaires divided by number ofquestionnaires that were started but not completed.AllQuestionnaires Average Time: For all questionnaires that were started,total time spent on questionnaires divided by number of startedquestionnaires.]]></text> </staticText> <textField pattern="MM/dd/yyyy h.mm a" isBlankWhenNull="true"> <reportElement x="0" y="386" width="1276" height="20"/> <textElement verticalAlignment="Middle"> <font size="10"/> </textElement> <textFieldExpression class="java.lang.String"><![CDATA[newSimpleDateFormat("MM/dd/yyyy h:mm a").format(newjava.util.Date())]]></textFieldExpression> </textField> <staticText> <reportElement stretchType="RelativeToBandHeight" x="565" y="66" width="215" height="30"/> <box bottomPadding="2" rightPadding="2"> <topPen lineWidth="1.0"/> <leftPen lineWidth="1.0"/> <bottomPen lineWidth="1.0"/> <rightPen lineWidth="1.0"/> </box> <textElement textAlignment="Center" verticalAlignment="Bottom"> <font size="12" isBold="true"/> </textElement> <text><![CDATA[Completed]]></text> </staticText> <staticText> <reportElement stretchType="RelativeToBandHeight" x="0" y="66" width="150" height="70"/> <box leftPadding="2" bottomPadding="2"> <topPen lineWidth="1.0"/> <leftPen lineWidth="1.0"/> <bottomPen lineWidth="1.0"/> <rightPen lineWidth="1.0"/> </box> <textElement textAlignment="Left" verticalAlignment="Bottom"> <font size="12" isBold="true"/> </textElement> <text><![CDATA[Kiosk Group]]></text> </staticText> <staticText> <reportElement x="565" y="96" width="125" height="40"/> <box bottomPadding="2" rightPadding="2"> <topPen lineWidth="1.0"/> <leftPen lineWidth="1.0"/> <bottomPen lineWidth="1.0"/> <rightPen lineWidth="1.0"/> </box> <textElement textAlignment="Right" verticalAlignment="Bottom"> <font size="12" isBold="true"/> </textElement> <text><![CDATA[Questionnaires]]></text> </staticText> <staticText> <reportElement stretchType="RelativeToBandHeight" x="350" y="66" width="215" height="30"/> <box bottomPadding="2" rightPadding="2"> <topPen lineWidth="1.0"/> <leftPen lineWidth="1.0"/> <bottomPen lineWidth="1.0"/> <rightPen lineWidth="1.0"/> </box> <textElement textAlignment="Center" verticalAlignment="Bottom"> <font size="12" isBold="true"/> </textElement> <text><![CDATA[started]]></text> </staticText> <staticText> <reportElement stretchType="RelativeToBandHeight" x="150" y="66" width="200" height="70"/> <box leftPadding="2" bottomPadding="2"> <topPen lineWidth="1.0"/> <leftPen lineWidth="1.0"/> <bottomPen lineWidth="1.0"/> <rightPen lineWidth="1.0"/> </box> <textElement textAlignment="Left" verticalAlignment="Bottom"> <font size="12" isBold="true"/> </textElement> <text><![CDATA[Questionnaire Name]]></text> </staticText> <staticText> <reportElement stretchType="RelativeToBandHeight" x="690" y="96" width="90" height="40"/> <box bottomPadding="2" rightPadding="2"> <topPen lineWidth="1.0"/> <leftPen lineWidth="1.0"/> <bottomPen lineWidth="1.0"/> <rightPen lineWidth="1.0"/> </box> <textElement textAlignment="Right" verticalAlignment="Bottom"> <font size="12" isBold="true"/> </textElement> <text><![CDATA[Patients]]></text> </staticText> <staticText> <reportElement stretchType="RelativeToBandHeight" x="350" y="96" width="125" height="40"/> <box bottomPadding="2" rightPadding="2"> <topPen lineWidth="1.0"/> <leftPen lineWidth="1.0"/> <bottomPen lineWidth="1.0"/> <rightPen lineWidth="1.0"/> </box> <textElement textAlignment="Right" verticalAlignment="Bottom"> <font size="12" isBold="true"/> </textElement> <text><![CDATA[Questionnaires]]></text> </staticText> <staticText> <reportElement stretchType="RelativeToBandHeight" x="475" y="96" width="90" height="40"/> <box bottomPadding="2" rightPadding="2"> <topPen lineWidth="1.0"/> <leftPen lineWidth="1.0"/> <bottomPen lineWidth="1.0"/> <rightPen lineWidth="1.0"/> </box> <textElement textAlignment="Right" verticalAlignment="Bottom"> <font size="12" isBold="true"/> </textElement> <text><![CDATA[Patients]]></text> </staticText> </band> </noData></jasperReport>[/code]
  7. I am having trouble with my 2nd level parameter. I am hoping someone can correct my syntax. My first parameter is single select and it works: <parameter name="QUESTIONNAIRE NAME" class="java.lang.String"><property name="parameter_type" value="select"/><property name="query" value="select distinct sd.display_name as displayName from srv_survey_definition sd where sd.active = true order by sd.display_name"/><parameterDescription><![CDATA[]]></parameterDescription><defaultValueExpression><![CDATA[]]></defaultValueExpression></parameter> My second parameter is multi-select and it should reference first parameter. It is not retrieving any results: <parameter name="DISPLAY NAME" class="java.util.List" isForPrompting="false"><property name="parameter_type" value="multiselect"/><property name="query" value="select distinct display_name from srv_survey_definition where split_part(survey_name,'_OUTDATED',1) IN (select survey_name from srv_survey_definition sd where and sd.display_name = $P{QUESTIONNAIRE NAME})"/><defaultValueExpression><![CDATA[java.util.Arrays.asList(new String(" "))]]></defaultValueExpression></parameter> Any suggestions are greatly appreciated.
  8. Where to find /reports/samples/Cascading_multi_select_report? I downloaded the Jasperserver and I don't see that in the reports/samples. Many thanks.
  9. I am having same problem. Would love to know if there is a solution.
  10. I solved my problem by changing the bucket expression for the NAME rowgroup to be $F{NAME} + "n" + $F{QUAL}
  11. According to the documentation, if you add a new row group, it should appear as in the below picture. Note that Row group 2 header appears below Row group 1 header. When I attempt to add a rowgroup (called "QUAL"), it is positioned to the right of my second row group. I want it to be positioned underneath row group 1 header (called "NAME"). How can I achieve this? This is what it looks like now: I've attached my source code. Thank you to anyone who can help!
  12. I am trying to prevent crosstab header from repeating when exporting to csv. I've tried the following (replacing "suffix" with group, band, report or crosstab): <property name="net.sf.jasperreports.export.csv.exclude.origin.keep.first.suffix.crosstabColumnHeader" value="crosstabColumnHeader"/> <property name="net.sf.jasperreports.export.csv.exclude.origin.keep.first.suffix.crosstabHeaderCell" value="crosstabHeaderCell"/> I'm not sure what to supply for a suffix or if this option exists. I'm not also sure if I've provided the correct values. Any help is appreciated! <?xml version="1.0" encoding="UTF-8"?> <jasperReport xmlns="http://jasperreports.sourceforge.net/jasperreports" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://jasperreports.sourceforge.net/jasperreports http://jasperreports.sourceforge.net/xsd/jasperreport.xsd" name="payroll_report_STD" pageWidth="792" pageHeight="612" orientation="Landscape" whenNoDataType="NoDataSection" columnWidth="754" leftMargin="19" rightMargin="19" topMargin="20" bottomMargin="20"> <property name="ireport.scriptlethandling" value="0"/> <property name="ireport.encoding" value="UTF-8"/> <property name="net.sf.jasperreports.export.csv.exclude.origin.keep.first.crosstab.crosstabColumnHeader" value="crosstabColumnHeader"/> <property name="net.sf.jasperreports.export.csv.exclude.origin.keep.first.crosstab.crosstabHeaderCell" value="crosstabHeaderCell"/> <property name="net.sf.jasperreports.export.csv.exclude.origin.band.columnFooter" value="columnFooter"/> <property name="net.sf.jasperreports.export.csv.exclude.origin.band.pageHeader" value="pageHeader"/> <property name="net.sf.jasperreports.export.csv.exclude.origin.band.pageFooter" value="pageFooter"/> <property name="net.sf.jasperreports.export.csv.exclude.origin.band.title" value="title"/> <property name="net.sf.jasperreports.export.csv.exclude.origin.band.lastPageFooter" value="lastPageFooter"/> <import value="net.sf.jasperreports.engine.*"/> <import value="java.util.*"/> <import value="net.sf.jasperreports.engine.data.*"/> <style name="Column Heading" isDefault="false" backcolor="#B0B0FF" vAlign="Middle" isBold="true"> <box leftPadding="3"/> </style> <style name="Text Field" isDefault="false" vAlign="Middle" isBlankWhenNull="true"> <box leftPadding="3"/> </style> <style name="Report Title" isDefault="false" hAlign="Right" vAlign="Middle" fontName="Arial" fontSize="18" isBold="false"/> <style name="Report Header" isDefault="false" vAlign="Middle" fontSize="12" isBold="true"/> <style name="Group Header" isDefault="false" vAlign="Middle" isBlankWhenNull="true" fontSize="14" isBold="true"/> <style name="Crosstab Data Text" isDefault="false" hAlign="Center"/> <parameter name="p_site_id" class="java.lang.String" isForPrompting="false"> <defaultValueExpression><![CDATA["DAL"]]></defaultValueExpression> </parameter> <parameter name="p_pay_period" class="java.lang.String"> <parameterDescription><![CDATA[<DN>Pay period</DN><LOV>select distinct to_char(start_date,'DD-MON-YY') || ' - ' || to_char(end_date,'DD-MON-YY') START_CH, start_date START_DT from pay_period where customer_department_id='$P!{p_customer_department_id}' order by start_dt desc</LOV>]]></parameterDescription> <defaultValueExpression><![CDATA["16-JUN-11 - 30-JUN-11"]]></defaultValueExpression> </parameter> <parameter name="p_noop" class="java.lang.String" isForPrompting="false"> <defaultValueExpression><![CDATA["1=1"]]></defaultValueExpression> </parameter> <parameter name="p_root_path" class="java.lang.String" isForPrompting="false"> <defaultValueExpression><![CDATA["."]]></defaultValueExpression> </parameter> <parameter name="p_customer_department_id" class="java.lang.String" isForPrompting="false"> <parameterDescription><![CDATA[]]></parameterDescription> <defaultValueExpression><![CDATA["SWADI"]]></defaultValueExpression> </parameter> <parameter name="P_CURRENT_DATE" class="java.lang.String" isForPrompting="false"/> <parameter name="p_worker_type" class="java.util.Collection"> <parameterDescription><![CDATA[<DN>Worker type</DN><LOV>select 'ALL' type, 1 dummy from dual union select employee_type_code type, 2 dummy from employee_type where customer_department_id = '$P!{p_customer_department_id}' and status='A' and employee_type_code <> 'NR' order by dummy,type</LOV>]]></parameterDescription> <defaultValueExpression><![CDATA[Arrays.asList(new String[] {"ALL"})]]></defaultValueExpression> </parameter> <parameter name="p_worker_type_string" class="java.lang.String" isForPrompting="false"> <defaultValueExpression><![CDATA[($P{p_worker_type}).toString().replaceAll("[\[\]]", "'").replaceAll(", ", "', '")]]></defaultValueExpression> </parameter> <parameter name="p_worker_type_query_string" class="java.lang.String" isForPrompting="false"> <defaultValueExpression><![CDATA["pr.work_type in (" + $P{p_worker_type_string} + ")"]]></defaultValueExpression> </parameter> <parameter name="p_worker_type_where_clause" class="java.lang.String" isForPrompting="false"> <defaultValueExpression><![CDATA[($P{p_worker_type_string}).matches("'ALL'") ? $P{p_noop} : $P{p_worker_type_query_string}]]></defaultValueExpression> </parameter> <parameter name="p_worker_type_string_1" class="java.lang.String" isForPrompting="false"> <defaultValueExpression><![CDATA[($P{p_worker_type}).toString().replaceAll("[\[\]]", "")]]></defaultValueExpression> </parameter> <parameter name="p_emp_name" class="java.util.Collection"> <parameterDescription><![CDATA[<DN>Worker name</DN><LOV>select 'ALL' name, 1 dummy from dual union select ed.last_name || ' ' || ed.first_name || ' ' || ed.middle_name name, 2 dummy from employee_detail ed, employee e where ed.is_fake = 'N' and e.employee_status_code = 'A' and e.employee_id = ed.employee_id and e.customer_department_id = '$P!{p_customer_department_id}' order by dummy</LOV>]]></parameterDescription> <defaultValueExpression><![CDATA[Arrays.asList(new String[] {"ALL"})]]></defaultValueExpression> </parameter> <parameter name="p_emp_name_string" class="java.lang.String" isForPrompting="false"> <defaultValueExpression><![CDATA[($P{p_emp_name}).toString().replaceAll("[\[\]]", "'").replaceAll(", ", "', '")]]></defaultValueExpression> </parameter> <parameter name="p_emp_name_string_1" class="java.lang.String" isForPrompting="false"> <defaultValueExpression><![CDATA[($P{p_emp_name}).toString().replaceAll("[\[\]]", " ")]]></defaultValueExpression> </parameter> <parameter name="p_emp_name_query_string" class="java.lang.String" isForPrompting="false"> <defaultValueExpression><![CDATA[" ed.last_name || ' ' || ed.first_name || ' ' || ed.middle_name in (" + $P{p_emp_name_string} + ")"]]></defaultValueExpression> </parameter> <parameter name="p_emp_name_where_clause" class="java.lang.String" isForPrompting="false"> <defaultValueExpression><![CDATA[($P{p_emp_name_string}).matches("'ALL'") ? $P{p_noop} : $P{p_emp_name_query_string}]]></defaultValueExpression> </parameter> <queryString> <![CDATA[sELECT --the nvl2 serves the purpose of eliminating the empty name row in crosstab with all zeros (lumps the null pay codes into another worker's row) nvl2(ed.last_name,ed.last_name || ', ' || ed.first_name || ' ' || ed.middle_name, (select last_name || ', ' || first_name || ' ' || middle_name from employee_detail q where rownum=1 and EXISTS (SELECT 'X' FROM payroll_report_view WHERE WORKER_ID=Q.EMPLOYEE_ID AND PAY_PERIOD = '$P!{p_pay_period}'))) NAME, nvl2(ed.alt_employee_id,ed.alt_employee_id,(select alt_employee_id from employee_detail q where rownum=1 and EXISTS (SELECT 'X' FROM payroll_report_view WHERE WORKER_ID=Q.EMPLOYEE_ID AND PAY_PERIOD = '$P!{p_pay_period}'))) WORKER_ID, nvl2(pr.work_type,pr.work_type,(select employee_type_code from employee q where rownum=1 and EXISTS (SELECT 'X' FROM payroll_report_view WHERE WORKER_ID=Q.EMPLOYEE_ID AND PAY_PERIOD = '$P!{p_pay_period}'))) WORK_TYPE, pr.pay_code PAY_CODE, pr.pc, pr.pay_rate PAY_RATE, decode(pr.pay_rate,0,pr.hours,null,pr.hours,(pr.hours*pr.pay_rate)) HOURS FROM --begin inline view (SELECT pc.pay_code PC, pc.external_code || chr(13) || ' (' || pc.pay_code || ')' || chr(13) || pc.description PAY_CODE, pr.hours HOURS, pr.worker_id, pr.work_type, pr.pay_period, pc.pay_rate FROM payroll_report_view pr, pay_code pc WHERE pr.pay_code_id (+) =pc.pay_code_id AND pr.pay_period (+) = '$P!{p_pay_period}' and $P!{p_worker_type_where_clause}) PR, --end inline view --begin inline view employee_detail ed --end inline view where pr.worker_id = ed.employee_id (+) and ed.is_fake (+) = 'N' and $P!{p_emp_name_where_clause} --begin pay code filter and (CASE WHEN EXISTS (SELECT 'X' FROM ARIS_REPORT_MANAGER_PARAMETER WHERE property_name='EXCLUDE-PAY-CODES' and report_name='payroll_report_STD' and customer_department_id = '$P!{p_customer_department_id}') and pr.pc not in (select regexp_substr(string_value,'[^ ]+', 1, level) from aris_report_manager_parameter where property_name='EXCLUDE-PAY-CODES' and report_name='payroll_report_STD' and customer_department_id = '$P!{p_customer_department_id}' connect by regexp_substr(string_value, '[^ ]+', 1, level) is not null) THEN 1 WHEN NOT EXISTS (SELECT 'X' FROM ARIS_REPORT_MANAGER_PARAMETER WHERE property_name='EXCLUDE-PAY-CODES' and report_name='payroll_report_STD' and customer_department_id = '$P!{p_customer_department_id}') THEN 1 ELSE 0 END) = 1 --end pay code filter ORDER BY NAME, work_type, pr.pay_code]]> </queryString> <field name="NAME" class="java.lang.String"> <fieldDescription><![CDATA[]]></fieldDescription> </field> <field name="WORKER_ID" class="java.lang.String"> <fieldDescription><![CDATA[]]></fieldDescription> </field> <field name="WORK_TYPE" class="java.lang.String"> <fieldDescription><![CDATA[]]></fieldDescription> </field> <field name="PAY_CODE" class="java.lang.String"> <fieldDescription><![CDATA[]]></fieldDescription> </field> <field name="PC" class="java.lang.String"> <fieldDescription><![CDATA[]]></fieldDescription> </field> <field name="PAY_RATE" class="java.math.BigDecimal"> <fieldDescription><![CDATA[]]></fieldDescription> </field> <field name="HOURS" class="java.math.BigDecimal"> <fieldDescription><![CDATA[]]></fieldDescription> </field> <group name="DUMMY"> <groupFooter> <band height="50"> <crosstab> <reportElement x="0" y="0" width="754" height="50"/> <crosstabDataset isDataPreSorted="true"> <dataset resetType="None"/> </crosstabDataset> <crosstabHeaderCell> <cellContents> <box> <topPen lineWidth="0.25"/> </box> <staticText> <reportElement style="Crosstab Data Text" stretchType="RelativeToTallestObject" x="0" y="0" width="100" height="62"/> <box topPadding="2" leftPadding="3"> <topPen lineWidth="0.25"/> <leftPen lineWidth="0.25"/> <rightPen lineWidth="0.25"/> </box> <textElement textAlignment="Left" markup="none"/> <text><![CDATA[Name]]></text> </staticText> <staticText> <reportElement style="Crosstab Data Text" stretchType="RelativeToTallestObject" x="100" y="0" width="65" height="62"/> <box topPadding="2" leftPadding="3"> <topPen lineWidth="0.25"/> <leftPen lineWidth="0.25"/> <rightPen lineWidth="0.25"/> </box> <textElement textAlignment="Left" markup="none"/> <text><![CDATA[iD]]></text> </staticText> <staticText> <reportElement style="Crosstab Data Text" stretchType="RelativeToTallestObject" x="165" y="0" width="55" height="62"/> <box topPadding="2" leftPadding="3"> <topPen lineWidth="0.25"/> <leftPen lineWidth="0.25"/> <rightPen lineWidth="0.25"/> </box> <textElement textAlignment="Left" markup="none"/> <text><![CDATA[Worker Type]]></text> </staticText> </cellContents> </crosstabHeaderCell> <rowGroup name="NAME" width="100" totalPosition="End"> <bucket> <bucketExpression class="java.lang.String"><![CDATA[$F{NAME}]]></bucketExpression> </bucket> <crosstabRowHeader> <cellContents backcolor="#FFFFFF" mode="Opaque"> <box> <pen lineWidth="0.5" lineStyle="Solid" lineColor="#000000"/> </box> <textField isBlankWhenNull="true"> <reportElement style="Crosstab Data Text" x="0" y="0" width="100" height="25"/> <box topPadding="2" leftPadding="3"/> <textElement textAlignment="Left"/> <textFieldExpression class="java.lang.String"><![CDATA[$V{NAME}]]></textFieldExpression> </textField> </cellContents> </crosstabRowHeader> <crosstabTotalRowHeader> <cellContents backcolor="#FFFFFF" mode="Opaque"> <box> <pen lineWidth="0.5" lineStyle="Solid" lineColor="#000000"/> </box> <staticText> <reportElement x="0" y="0" width="100" height="25"/> <box leftPadding="3"> <pen lineWidth="0.25"/> <topPen lineWidth="0.25"/> <leftPen lineWidth="0.25"/> <bottomPen lineWidth="0.25"/> <rightPen lineWidth="0.25"/> </box> <textElement textAlignment="Left" verticalAlignment="Middle"/> <text><![CDATA[Total]]></text> </staticText> </cellContents> </crosstabTotalRowHeader> </rowGroup> <rowGroup name="WORKER_ID" width="65"> <bucket> <bucketExpression class="java.lang.String"><![CDATA[$F{WORKER_ID}]]></bucketExpression> </bucket> <crosstabRowHeader> <cellContents> <box> <pen lineWidth="0.25"/> <topPen lineWidth="0.25"/> <leftPen lineWidth="0.25"/> <bottomPen lineWidth="0.25"/> <rightPen lineWidth="0.25"/> </box> <textField isBlankWhenNull="true"> <reportElement style="Crosstab Data Text" x="0" y="0" width="65" height="25"/> <box topPadding="2" leftPadding="3"/> <textElement textAlignment="Left"/> <textFieldExpression class="java.lang.String"><![CDATA[$V{WORKER_ID}]]></textFieldExpression> </textField> </cellContents> </crosstabRowHeader> <crosstabTotalRowHeader> <cellContents> <staticText> <reportElement x="100" y="87" width="65" height="25"/> <box leftPadding="3"> <pen lineWidth="0.25"/> <topPen lineWidth="0.25"/> <leftPen lineWidth="0.25"/> <bottomPen lineWidth="0.25"/> <rightPen lineWidth="0.25"/> </box> <textElement textAlignment="Left" verticalAlignment="Middle"/> <text><![CDATA[]]></text> </staticText> </cellContents> </crosstabTotalRowHeader> </rowGroup> <rowGroup name="WORK_TYPE" width="55"> <bucket> <bucketExpression class="java.lang.String"><![CDATA[$F{WORK_TYPE}]]></bucketExpression> </bucket> <crosstabRowHeader> <cellContents> <box> <pen lineWidth="0.25"/> <topPen lineWidth="0.25"/> <leftPen lineWidth="0.25"/> <bottomPen lineWidth="0.25"/> <rightPen lineWidth="0.25"/> </box> <textField isBlankWhenNull="true"> <reportElement style="Crosstab Data Text" x="0" y="0" width="55" height="25" isRemoveLineWhenBlank="true"/> <box topPadding="2" leftPadding="3"/> <textElement/> <textFieldExpression class="java.lang.String"><![CDATA[$V{WORK_TYPE}]]></textFieldExpression> </textField> </cellContents> </crosstabRowHeader> <crosstabTotalRowHeader> <cellContents> <staticText> <reportElement x="165" y="87" width="55" height="25"/> <box leftPadding="3"> <pen lineWidth="0.25"/> <topPen lineWidth="0.25"/> <leftPen lineWidth="0.25"/> <bottomPen lineWidth="0.25"/> <rightPen lineWidth="0.25"/> </box> <textElement textAlignment="Left" verticalAlignment="Middle"/> <text><![CDATA[]]></text> </staticText> </cellContents> </crosstabTotalRowHeader> </rowGroup> <columnGroup name="PAY_CODE" height="62"> <bucket> <bucketExpression class="java.lang.String"><![CDATA[$F{PAY_CODE}]]></bucketExpression> </bucket> <crosstabColumnHeader> <cellContents backcolor="#FFFFFF" mode="Opaque"> <box> <pen lineWidth="0.5" lineStyle="Solid" lineColor="#000000"/> </box> <textField isStretchWithOverflow="true"> <reportElement style="Crosstab Data Text" stretchType="RelativeToTallestObject" x="0" y="0" width="53" height="62"/> <box topPadding="2" leftPadding="1" rightPadding="3"/> <textElement/> <textFieldExpression class="java.lang.String"><![CDATA[$V{PAY_CODE}]]></textFieldExpression> </textField> </cellContents> </crosstabColumnHeader> <crosstabTotalColumnHeader> <cellContents/> </crosstabTotalColumnHeader> </columnGroup> <measure name="HOURSMeasure" class="java.math.BigDecimal" calculation="Sum"> <measureExpression><![CDATA[$F{HOURS}]]></measureExpression> </measure> <measure name="PCmeasure" class="java.lang.String"> <measureExpression><![CDATA[$F{PC}]]></measureExpression> </measure> <measure name="PAY_RATEmeasure" class="java.math.BigDecimal"> <measureExpression><![CDATA[$F{PAY_RATE}]]></measureExpression> </measure> <crosstabCell width="53" height="25"> <cellContents> <box> <pen lineWidth="0.5" lineStyle="Solid" lineColor="#000000"/> </box> <textField isBlankWhenNull="true"> <reportElement style="Crosstab Data Text" x="0" y="0" width="53" height="25"/> <box topPadding="2"/> <textElement/> <textFieldExpression class="java.math.BigDecimal"><![CDATA[$V{HOURSMeasure}]]></textFieldExpression> </textField> <staticText> <reportElement style="Crosstab Data Text" x="0" y="0" width="15" height="25"> <printWhenExpression><![CDATA[boolean.valueOf($V{PAY_RATEmeasure}.intValue()>0)]]></printWhenExpression> </reportElement> <box topPadding="2" leftPadding="2"/> <textElement textAlignment="Left"/> <text><![CDATA[$]]></text> </staticText> </cellContents> </crosstabCell> <crosstabCell width="53" height="25" rowTotalGroup="NAME"> <cellContents backcolor="#FFFFFF" mode="Opaque"> <box> <pen lineWidth="0.5" lineStyle="Solid" lineColor="#000000"/> </box> <textField> <reportElement style="Crosstab Data Text" x="0" y="0" width="53" height="25"/> <box topPadding="2"/> <textElement/> <textFieldExpression class="java.math.BigDecimal"><![CDATA[$V{HOURSMeasure}]]></textFieldExpression> </textField> <staticText> <reportElement style="Crosstab Data Text" x="0" y="0" width="15" height="25"> <printWhenExpression><![CDATA[boolean.valueOf($V{PAY_RATEmeasure}.intValue()>0)]]></printWhenExpression> </reportElement> <box topPadding="2" leftPadding="2"/> <textElement textAlignment="Left"/> <text><![CDATA[$]]></text> </staticText> </cellContents> </crosstabCell> <crosstabCell width="45" columnTotalGroup="PAY_CODE"> <cellContents backcolor="#FFE4BF" mode="Opaque"> <box> <pen lineWidth="0.5" lineStyle="Solid" lineColor="#000000"/> </box> <textField> <reportElement style="Crosstab Data Text" x="0" y="0" width="45" height="25"/> <textElement/> <textFieldExpression class="java.math.BigDecimal"><![CDATA[$V{HOURSMeasure}]]></textFieldExpression> </textField> </cellContents> </crosstabCell> <crosstabCell rowTotalGroup="NAME" columnTotalGroup="PAY_CODE"> <cellContents backcolor="#FFE4BF" mode="Opaque"> <box> <pen lineWidth="0.5" lineStyle="Solid" lineColor="#000000"/> </box> <textField> <reportElement style="Crosstab Data Text" x="0" y="0" width="45" height="25"/> <textElement/> <textFieldExpression class="java.math.BigDecimal"><![CDATA[$V{HOURSMeasure}]]></textFieldExpression> </textField> </cellContents> </crosstabCell> <crosstabCell rowTotalGroup="WORKER_ID"> <cellContents/> </crosstabCell> <crosstabCell rowTotalGroup="WORKER_ID" columnTotalGroup="PAY_CODE"> <cellContents/> </crosstabCell> <crosstabCell rowTotalGroup="WORK_TYPE"> <cellContents/> </crosstabCell> <crosstabCell rowTotalGroup="WORK_TYPE" columnTotalGroup="PAY_CODE"> <cellContents/> </crosstabCell> </crosstab> </band> </groupFooter> </group> <background> <band splitType="Stretch"/> </background> <title> <band height="63" splitType="Stretch"> <image scaleImage="FillFrame" hAlign="Left" vAlign="Top" isUsingCache="true"> <reportElement key="image-1" positionType="Float" mode="Opaque" x="0" y="0" width="754" height="63" forecolor="#000000" backcolor="#FFFFFF"/> <box> <topPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> <leftPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> <bottomPen lineWidth="0.0" lineColor="#000000"/> <rightPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> </box> <graphicElement fill="Solid"> <pen lineWidth="0.0" lineStyle="Solid"/> </graphicElement> <imageExpression class="java.lang.String"><![CDATA[$P{p_root_path} + "/images/report-header-landscape.gif"]]></imageExpression> </image> <staticText> <reportElement key="staticText-12" x="442" y="15" width="312" height="25"/> <box> <topPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> <leftPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> <bottomPen lineWidth="0.0" lineColor="#000000"/> <rightPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> </box> <textElement textAlignment="Right" verticalAlignment="Middle"> <font fontName="Arial" size="18" isBold="true" pdfFontName="Helvetica-Bold"/> </textElement> <text><![CDATA[Payroll report]]></text> </staticText> <staticText> <reportElement key="staticText-17" positionType="Float" mode="Transparent" x="590" y="49" width="52" height="9" forecolor="#FFE382" backcolor="#CCCCCC"/> <box> <topPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> <leftPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> <bottomPen lineWidth="0.0" lineColor="#000000"/> <rightPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> </box> <textElement textAlignment="Left" verticalAlignment="Top" rotation="None" lineSpacing="Single"> <font fontName="Arial" size="7" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfFontName="Helvetica-Bold" pdfEncoding="Cp1252" isPdfEmbedded="false"/> </textElement> <text><![CDATA[Report run on: ]]></text> </staticText> <textField pattern="" isBlankWhenNull="false"> <reportElement key="textField-12" positionType="Float" mode="Transparent" x="646" y="49" width="106" height="9" isPrintWhenDetailOverflows="true" forecolor="#CCCCCC" backcolor="#FFFFFF"/> <box> <topPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> <leftPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> <bottomPen lineWidth="0.0" lineColor="#000000"/> <rightPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> </box> <textElement textAlignment="Left" verticalAlignment="Middle" rotation="None" lineSpacing="Single"> <font fontName="Arial" size="7" isBold="true" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfFontName="Helvetica" pdfEncoding="Cp1252" isPdfEmbedded="false"/> </textElement> <textFieldExpression class="java.lang.String"><![CDATA[$P{P_CURRENT_DATE}]]></textFieldExpression> </textField> <subreport isUsingCache="true"> <reportElement key="subreport-2" x="0" y="0" width="125" height="43"/> <subreportParameter name="p_customer_department_id"> <subreportParameterExpression><![CDATA[$P{p_customer_department_id}]]></subreportParameterExpression> </subreportParameter> <connectionExpression><![CDATA[$P{REPORT_CONNECTION}]]></connectionExpression> <subreportExpression class="java.lang.String"><![CDATA[$P{p_root_path} + "/report_logo.jasper"]]></subreportExpression> </subreport> </band> </title> <pageHeader> <band height="30" splitType="Stretch"> <textField> <reportElement x="0" y="0" width="754" height="30"/> <textElement> <font size="12" isBold="true"/> </textElement> <textFieldExpression class="java.lang.String"><![CDATA["Payroll for pay period " + $P{p_pay_period} + ", worker type " + $P{p_worker_type_string_1} + ", worker " + $P{p_emp_name_string_1}]]></textFieldExpression> </textField> </band> </pageHeader> <columnHeader> <band splitType="Stretch"/> </columnHeader> <detail> <band splitType="Prevent"/> </detail> <columnFooter> <band splitType="Stretch"/> </columnFooter> <pageFooter> <band height="22" splitType="Stretch"> <staticText> <reportElement key="staticText-7" positionType="Float" mode="Transparent" x="653" y="10" width="29" height="12" forecolor="#000000" backcolor="#FFFFFF"/> <box> <topPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> <leftPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> <bottomPen lineWidth="0.0" lineColor="#000000"/> <rightPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> </box> <textElement textAlignment="Right" verticalAlignment="Top" rotation="None" lineSpacing="Single"> <font fontName="Arial" size="10" isBold="false" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfFontName="Helvetica" pdfEncoding="Cp1252" isPdfEmbedded="false"/> </textElement> <text><![CDATA[Page]]></text> </staticText> <textField isStretchWithOverflow="true" pattern="" isBlankWhenNull="false"> <reportElement key="textField-7" positionType="Float" mode="Transparent" x="685" y="10" width="24" height="12" forecolor="#000000" backcolor="#FFFFFF"/> <box> <topPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> <leftPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> <bottomPen lineWidth="0.0" lineColor="#000000"/> <rightPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> </box> <textElement textAlignment="Center" verticalAlignment="Bottom" rotation="None" lineSpacing="Single"> <font fontName="Arial" size="10" isBold="false" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfFontName="Helvetica" pdfEncoding="Cp1252" isPdfEmbedded="false"/> </textElement> <textFieldExpression class="java.lang.Integer"><![CDATA[$V{PAGE_NUMBER}]]></textFieldExpression> </textField> <staticText> <reportElement key="staticText-8" positionType="Float" mode="Transparent" x="709" y="10" width="18" height="12" forecolor="#000000" backcolor="#FFFFFF"/> <box> <topPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> <leftPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> <bottomPen lineWidth="0.0" lineColor="#000000"/> <rightPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> </box> <textElement textAlignment="Center" verticalAlignment="Top" rotation="None" lineSpacing="Single"> <font fontName="Arial" size="10" isBold="false" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfFontName="Helvetica" pdfEncoding="Cp1252" isPdfEmbedded="false"/> </textElement> <text><![CDATA[of]]></text> </staticText> <textField evaluationTime="Report" pattern="" isBlankWhenNull="false"> <reportElement key="textField-8" positionType="Float" mode="Transparent" x="728" y="10" width="24" height="12" forecolor="#000000" backcolor="#FFFFFF"/> <box> <topPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> <leftPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> <bottomPen lineWidth="0.0" lineColor="#000000"/> <rightPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> </box> <textElement textAlignment="Center" verticalAlignment="Bottom" rotation="None" lineSpacing="Single"> <font fontName="Arial" size="10" isBold="false" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfFontName="Helvetica" pdfEncoding="Cp1252" isPdfEmbedded="false"/> </textElement> <textFieldExpression class="java.lang.Integer"><![CDATA[$V{PAGE_NUMBER}]]></textFieldExpression> </textField> </band> </pageFooter> <lastPageFooter> <band height="20" splitType="Stretch"> <staticText> <reportElement key="staticText-16" positionType="Float" mode="Transparent" x="0" y="8" width="188" height="12" forecolor="#000000" backcolor="#FFFFFF"/> <box> <topPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> <leftPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> <bottomPen lineWidth="0.0" lineColor="#000000"/> <rightPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> </box> <textElement textAlignment="Left" verticalAlignment="Top" rotation="None" lineSpacing="Single"> <font fontName="Arial" size="8" isBold="false" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfFontName="Helvetica" pdfEncoding="Cp1252" isPdfEmbedded="false"/> </textElement> <text><![CDATA[Version 20120921]]></text> </staticText> <staticText> <reportElement key="staticText-18" positionType="Float" mode="Transparent" x="653" y="8" width="29" height="12" forecolor="#000000" backcolor="#FFFFFF"/> <box> <topPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> <leftPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> <bottomPen lineWidth="0.0" lineColor="#000000"/> <rightPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> </box> <textElement textAlignment="Right" verticalAlignment="Top" rotation="None" lineSpacing="Single"> <font fontName="Arial" size="10" isBold="false" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfFontName="Helvetica" pdfEncoding="Cp1252" isPdfEmbedded="false"/> </textElement> <text><![CDATA[Page]]></text> </staticText> <textField isStretchWithOverflow="true" pattern="" isBlankWhenNull="false"> <reportElement key="textField-13" positionType="Float" mode="Transparent" x="685" y="8" width="24" height="12" forecolor="#000000" backcolor="#FFFFFF"/> <box> <topPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> <leftPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> <bottomPen lineWidth="0.0" lineColor="#000000"/> <rightPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> </box> <textElement textAlignment="Center" verticalAlignment="Bottom" rotation="None" lineSpacing="Single"> <font fontName="Arial" size="10" isBold="false" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfFontName="Helvetica" pdfEncoding="Cp1252" isPdfEmbedded="false"/> </textElement> <textFieldExpression class="java.lang.Integer"><![CDATA[$V{PAGE_NUMBER}]]></textFieldExpression> </textField> <staticText> <reportElement key="staticText-19" positionType="Float" mode="Transparent" x="709" y="8" width="18" height="12" forecolor="#000000" backcolor="#FFFFFF"/> <box> <topPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> <leftPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> <bottomPen lineWidth="0.0" lineColor="#000000"/> <rightPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> </box> <textElement textAlignment="Center" verticalAlignment="Top" rotation="None" lineSpacing="Single"> <font fontName="Arial" size="10" isBold="false" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfFontName="Helvetica" pdfEncoding="Cp1252" isPdfEmbedded="false"/> </textElement> <text><![CDATA[of]]></text> </staticText> <textField evaluationTime="Report" pattern="" isBlankWhenNull="false"> <reportElement key="textField-14" positionType="Float" mode="Transparent" x="728" y="8" width="24" height="12" forecolor="#000000" backcolor="#FFFFFF"/> <box> <topPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> <leftPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> <bottomPen lineWidth="0.0" lineColor="#000000"/> <rightPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> </box> <textElement textAlignment="Center" verticalAlignment="Bottom" rotation="None" lineSpacing="Single"> <font fontName="Arial" size="10" isBold="false" isItalic="false" isUnderline="false" isStrikeThrough="false" pdfFontName="Helvetica" pdfEncoding="Cp1252" isPdfEmbedded="false"/> </textElement> <textFieldExpression class="java.lang.Integer"><![CDATA[$V{PAGE_NUMBER}]]></textFieldExpression> </textField> </band> </lastPageFooter> <summary> <band height="100" splitType="Stretch"> <subreport> <reportElement x="0" y="0" width="754" height="50"/> <subreportParameter name="p_customer_department_id"> <subreportParameterExpression><![CDATA[$P{p_customer_department_id}]]></subreportParameterExpression> </subreportParameter> <subreportParameter name="p_emp_name"> <subreportParameterExpression><![CDATA[$P{p_emp_name}]]></subreportParameterExpression> </subreportParameter> <subreportParameter name="p_pay_period"> <subreportParameterExpression><![CDATA[$P{p_pay_period}]]></subreportParameterExpression> </subreportParameter> <subreportParameter name="p_worker_type"> <subreportParameterExpression><![CDATA[$P{p_worker_type}]]></subreportParameterExpression> </subreportParameter> <connectionExpression><![CDATA[$P{REPORT_CONNECTION}]]></connectionExpression> <subreportExpression class="java.lang.String"><![CDATA[$P{p_root_path} + "/payroll_STD_subreport0.jasper"]]></subreportExpression> </subreport> <subreport> <reportElement x="0" y="50" width="754" height="50"/> <subreportParameter name="p_customer_department_id"> <subreportParameterExpression><![CDATA[$P{p_customer_department_id}]]></subreportParameterExpression> </subreportParameter> <subreportParameter name="p_emp_name"> <subreportParameterExpression><![CDATA[$P{p_emp_name}]]></subreportParameterExpression> </subreportParameter> <subreportParameter name="p_pay_period"> <subreportParameterExpression><![CDATA[$P{p_pay_period}]]></subreportParameterExpression> </subreportParameter> <subreportParameter name="p_worker_type"> <subreportParameterExpression><![CDATA[$P{p_worker_type}]]></subreportParameterExpression> </subreportParameter> <connectionExpression><![CDATA[$P{REPORT_CONNECTION}]]></connectionExpression> <subreportExpression class="java.lang.String"><![CDATA[$P{p_root_path} + "/payroll_STD_subreport1.jasper"]]></subreportExpression> </subreport> </band> </summary> <noData> <band height="30" splitType="Stretch"> <staticText> <reportElement key="staticText-15" x="0" y="11" width="754" height="19"> <printWhenExpression><![CDATA[new Boolean($V{REPORT_COUNT}.intValue()==0)]]></printWhenExpression> </reportElement> <box> <topPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> <leftPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> <bottomPen lineWidth="0.0" lineColor="#000000"/> <rightPen lineWidth="0.0" lineStyle="Solid" lineColor="#000000"/> </box> <textElement textAlignment="Center"> <font size="12"/> </textElement> <text><![CDATA[No data was retrieved; please check your report selections.]]></text> </staticText> </band> </noData> </jasperReport>
  13. ktalarico Wrote: Would you be able to provide an example? Thanks in advance. Oops, never mind; I figured it out. Thanks for the great tip Kate!!
  14. Would you be able to provide an example? Thanks in advance.
  15. I'm posting the code for the custom incrementer factory (I did not write it, so I couldn't explain it). I'm also attaching the report that uses it. It has employee names on the left, shift dates on the top and shifts in the detail cell (employee can work more than one shift in a day). However, this is a limited solution because it only allows up to 3 values to be displayed in the detail cell. I'm looking for another solution that allows an unlimited number of values to be displayed in a detail cell. Code: Post Edited by ktalarico at 10/12/2011 18:00
  16. Great post everyone; I can't believe this was so easy and I had been struggling with it for so long. Thank you!
  17. I am interested this feature as well - a way to configure which bands get exported to CSV/Excel.
  18. Okay. I saw on another post that a bug report has been created.
  19. I am having the same problem. I really don't want to change all of the font sizes in my source files. Is this the intended behavior? If so, is there a workaround to get everything to display correctly in PDF? I'm attaching pdf files for examples. Also attaching the source file. Post Edited by ktalarico at 06/30/2011 15:40
  20. I am having same problem with displaying image selected as Oracle BLOB from table. It always worked in previous versions of iReport (up to 3.7.0). I just migrated to 4.0.2, and it is throwing an error. Any suggestions? Source file attached. Error filling print... Error evaluating expression : Source text : ($F{IMAGE_DATA}).getBinaryStream() net.sf.jasperreports.engine.fill.JRExpressionEvalException: Error evaluating expression : Source text : ($F{IMAGE_DATA}).getBinaryStream() at net.sf.jasperreports.engine.fill.JREvaluator.evaluate(JREvaluator.java:195) at net.sf.jasperreports.engine.fill.JRCalculator.evaluate(JRCalculator.java:589) at net.sf.jasperreports.engine.fill.JRCalculator.evaluate(JRCalculator.java:557) at net.sf.jasperreports.engine.fill.JRFillElement.evaluateExpression(JRFillElement.java:929) at net.sf.jasperreports.engine.fill.JRFillImage.evaluateImage(JRFillImage.java:1023) at net.sf.jasperreports.engine.fill.JRFillImage.evaluate(JRFillImage.java:1004) at net.sf.jasperreports.engine.fill.JRFillElementContainer.evaluate(JRFillElementContainer.java:258) at net.sf.jasperreports.engine.fill.JRFillBand.evaluate(JRFillBand.java:499) at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillColumnBand(JRVerticalFiller.java:2036) at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillDetail(JRVerticalFiller.java:760) at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillReportStart(JRVerticalFiller.java:270) at net.sf.jasperreports.engine.fill.JRVerticalFiller.fillReport(JRVerticalFiller.java:128) at net.sf.jasperreports.engine.fill.JRBaseFiller.fill(JRBaseFiller.java:946) at net.sf.jasperreports.engine.fill.JRBaseFiller.fill(JRBaseFiller.java:845) at net.sf.jasperreports.engine.fill.JRFiller.fillReport(JRFiller.java:58) at net.sf.jasperreports.engine.JasperFillManager.fillReport(JasperFillManager.java:417) at net.sf.jasperreports.engine.JasperFillManager.fillReport(JasperFillManager.java:247) at com.jaspersoft.ireport.designer.compiler.IReportCompiler.run(IReportCompiler.java:878) at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:572) at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:997) Caused by: java.lang.ClassCastException: oracle.sql.BLOB cannot be cast to oracle.sql.BLOB at report_logo_1309445227547_746974.evaluate(report_logo_1309445227547_746974:180) at net.sf.jasperreports.engine.fill.JREvaluator.evaluate(JREvaluator.java:182) ... 19 more
  21. Should an element be able to float if it is in the detail cell of a crosstab? I am wondering because it is not working for me. If I tell an element to float, it always is positioned at the top regardless.
  22. >first, you have to place your crosstab object into summary section. That is not true, but thank you for your quick reply I have since solved the problem. One of the java developers here wrote a custom incrementer factory class for me.
×
×
  • Create New...