Hello, I am building a report with a subreport, but keep getting the same error. Pertinent report code: <queryString> <![CDATA[select pofr.id as pofrid, from product_orders_for_reports pofr where pofr.id = 1773589]]> </queryString> <field name="pofrid" class="java.lang.Integer"/> <detail> <band height="671" splitType="Stretch"> <subreport> <reportElement x="40" y="450" width="200" height="200" uuid="04e3d2b5-27e3-4cf8-921c-7471b7bda468"/> <subreportParameter name="POFR_ID"> <subreportParameterExpression><![CDATA[1773589]]></subreportParameterExpression> </subreportParameter> <connectionExpression><![CDATA[$P{REPORT_CONNECTION}]]></connectionExpression> <subreportExpression><![CDATA["consumer_subreport.jasper"]]></subreportExpression> </subreport> </band> </detail> Pertinent subreport code: <parameter name="POFR_ID" class="java.lang.Integer"> <defaultValueExpression><![CDATA["1773589"]]></defaultValueExpression> </parameter> <queryString language="SQL"> <![CDATA[select pofr.id from where pofr.id = $P{POFR_ID}]]> </queryString> And the error text: ......JRException: Error preparing statement for executing the report query: select .... where pofr.id = '?' .......Caused by: .... The column index is out of range: 1, number of columns: 0. Does anyone have an idea why this is happening, and what I can do to fix it? Thanks! EDIT: Also, the subreport runs perfectly fine on its own if the pofr.id is hardcoded, and the report runs fine when no subreport is hooked up. The subreport parameter POFR_ID should take the field variable pofrid from the main report, but I get the same error no matter what is passed into it.