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

vinayt

Members
  • Posts

    6
  • Joined

  • Last visited

vinayt's Achievements

  1. After searching for around 4 days, i found a solution. Jasper Server allows the SQL queries that starts with only "SELECT" keyword. So in order to make other queries work, we have to modify a regular expression of "Validator.ValidSQL" that is present in "webapps/jasperserver/WEB-INF/classes/esapi/security-config.properties/validation.properties" location. I have modified this regular expression to support 'IF' conditions and made it work. Got this solution from jasper community forum: http://community.jaspersoft.com/questions/800208/stored-procedures-works-ireport-does-not-work-jasperserver.
  2. I have the following sample query: IF(1=1) Select top 10 * from Person ELSE Select top 10 * from Person where Id < 20[/code]When i create a report with above query using Ireport , the report works fine. But when i upload the same report to jasper server and try to run the report, it is throwing the below error. ERROR Validator,report1 subreports #1:493 - Invalid SQL:An error has occurred. Please contact your system administrator. (6632), SQL: IF(1=1)Select top 10 * from PersonELSESelect top 10 * from Person where Id < 20.[/code]Does Jasper server supports IF..Else conditions outside the SELECT statements.? Do any one know about this error? Thanks in advance
  3. Hi Robi, How did you solve this problem. Am in the similar situation. Thanks, Vinay
  4. Am new to JasperReports. As part of creating a query in report, am facing an issue. I have a sql query similar to below one : am trying to convert a date value to different date using a user defined SQL Function. Select * from Person where (CreatedDate < dbo.ConvertLocalDateToUTC($P{dsRegistration_attemptEndDt_pDate_MinRange} + ' 00:00:00',$P{UserTimeZoneFK}))[/code] How can i write the same Where clause in JasperReports using $X{} as the where clause contains a user defined function? I tried to write as below, but it is not working. Select * from Person where $X{LESS, CreatedDate, dbo.ConvertLocalDateToUTC($P{dsRegistration_attemptEndDt_pDte_MinRange} + ' 00:00:00',$P{UserTimeZoneFK}) }[/code] Can any one please let me know, how can i use the Sql user-defined functions in sql queries ofJasperReports. Am working on this from 2 days, but still i couldn't get anything.
  5. Hi, I would like to know whether it is possible to have grouping in the list component in Jasper. The List contains a Text field which is basically a grouping field and a table which contains the data for that group. Please let me know whether this is possible or not. Thanks, Vinay.
×
×
  • Create New...