How can we use ireport paramerter in sql query column

0

In i Report I'm using parameter in SQL query, but the parameter field is not showing in the data set. I have a fee Structure Table which 12 Months Columns for Amount, I'm trying to get the desire month by passing the parameter as column, but the parameter column is not showing in the data field. Here is my Query, I'm Passing 

FeeStructure.$P!{Months}<span style="color: rgb(34, 34, 34); font-family: 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 15px; line-height: 19.5px; background-color: rgb(255, 255, 255);"> as a Parameter Column.</span></p>
<p>SELECT        StudentInformation.ID, School.School,School.Logo, Branch.BranchName, Parents.Parents, StudentInformation.StudentName, ClassS.Class, Section.Section,</p>
<p>                         StudentInformation.AdmissionNo, StudentInformation.NOC, StudentInformation.FatherName<br />
FROM            StudentInformation INNER JOIN<br />
                         Branch ON StudentInformation.BranchID = Branch.ID INNER JOIN<br />
                         ClassS ON StudentInformation.[C/Class] = ClassS.Id INNER JOIN<br />
                         Parents ON StudentInformation.ParentID = Parents.ID INNER JOIN<br />
                         School ON StudentInformation.SchoolID = School.ID AND Branch.SchoolID = School.ID INNER JOIN<br />
                         Section ON StudentInformation.[C/Section] = Section.ID</p>
haideraqeel86's picture
Joined: Oct 19 2014 - 5:07am
Last seen: 5 months 1 week ago

1 Answer:

0

Should be using Jaspersoft Studio because iReport development has ended.

In Jaspersoft Studio, just create a parameter "Month" and use $P{"Month") in your sql statement.

 

hozawa's picture
47007
Joined: Apr 24 2010 - 4:31pm
Last seen: 2 months 1 week ago
Feedback