Common errors encountered in the use of Java Report Tools Finereport and their solutions

Source: Internet
Author: User
Tags mysql code mysql database

For information about Java report Tools Finereport Common functions and examples, please click here. Http://www.111cn.net/jsp/Jsp-Servlet/83901.htm

(i)

1. Address pool are full:

Meaning: The address pool is full, the number of connections exceeds the upper limit of concurrency.

Solution:

In the setting of the Finereport connection pool properties, the maximum number of connections has been set too large, and there is an error, as is usually the case when the database process (processes) reaches the upper limit, which increases the number of connections in the database to resolve the problem. The following changes the maximum number of connections in the database:

Select Count (*) from v$process view current number of connections

Select valuefrom v$parameter where name= ' processes ' to see the maximum number of connections allowed by the database

Alter system setprocesses =300 scope = spfile; Modify maximum number of connections

Restart the database, and then query the maximum number of connections, the number changes will indicate that the modified successfully.

Note: When a client releases a database connection, first determine whether the number of references to the connection has exceeded the specified value, if more than delete the connection, and determine whether the current connection pool total number of connections is less than minconn (minimum number of connections), if less than the connection pool is covered; if not more than the connection will be marked as open, Available for reuse. It can be seen that this set of strategies ensures the efficient reuse of database connections and avoids the overhead of system resources caused by frequent connection creation and release.



2, the use of unregistered features:

Meaning:

Unregistered versions are available to try out all the features. The registered LIC is checked by the function point, if the template is made use of unregistered features will be reported this error. Generally easy to distinguish, some customers may be banned from the error interface, so the test is good, a put on the server will not come out, no error-prone interface is not easy to find.

Workaround: This feature is not available in the formal environment where the purchase is registered, if some features are not purchased.

If you want to know what is available in the version you purchased, open the Web server and enter it in the browser: Http://localhost:8075/WebReport/ReportServer?op=fs Enter the FR system interface, click Management System > Register Information > features list to see what features this release supports, as shown in the following figure:




3, Prompt registration:

Meaning: The unregistered version is used.

Solution: Registration FAQ: http://www.finereporthelp.com/help/9/4.html



4, Session timed out:

Meaning: Session timeout.

Solution: Set the session sticky, through the configuration file configuration, will be in the cluster of servers to establish contacts, when the server received a request, found that the request of the conversation is not its own generation, then it will be based on the information in the request to determine the session is generated by which server. It then forwards the request through the intranet to the corresponding server to process. This is equivalent to achieve the Java-EE cluster session sticky function. Specific operation parameter documentation: server cluster configuration steps.

(b)


1. No data set returned:

Precede the action statement in the stored procedure with the SET NOCOUNT on or precede the data set exec call stored procedure. When set NOCOUNT is on, the count is not returned (representing the number of rows affected by Transact-SQL statements). When SET NOCOUNT is off, the count is returned. If some of the statements contained in a stored procedure do not return much of the actual data, this setting can significantly improve performance because of a significant reduction in network traffic.

2, template file damage, or open template does not respond:

Finereport's CPT template is a statement that the designer makes the source file the label of a group of groups. Like the structure of HTML, you can open it with a text editor. Some of the customer's templates may do a comparison of BT, or a high or low version of the mess, or is operating what the DT situation caused the template is incomplete. The general error will tell the location of the errors.

3, can not find the template:

Could not find the template possible reasons to see if the problem is not a URL, directly in the template to write in Chinese, some browsers will automatically transcoding (remember Chrome, Sogou seems to be), some will not, such as IE.


4, Java heapspace, stack overflow:

This is the mother of the question. The common reason is that templates do a very complex, with hundreds of fields, hundreds of lines of SQL statements, various nesting, especially to pay attention to the dead loop. It can also be a server-side problem, such as Tomcat Max memory is too small to use the default 64M.


5, the dataset definition has a drop-down check box parameter problem:

The Drop-down check box control returns a value that is an array by default, and the string to which the parameter is fetched is not quoted (so the string type argument in the dataset-defined SQL statement is manually prefixed with a single quotation mark). Multiple values with In,sql in statement arguments are string arrays, each of which requires single quotes. So to convert, change the return value of the control to a string, and the spacer with ', '.


6, the effect of local preview and the effect on the server is not the same:

First check the jar pack and so on is not a problem. It may also be a problem that occurs when you embed a platform.


7, platform management forgot the password or login:

Report platform management only one account, username and password are placed in the web-inf/resources/privilege.xml. You can reset it by deleting it.


8, the Chart Chinese garbled (box):

This is easy to do when Oracle is installed in this Linux environment, and the box is short of Chinese fonts (common English fonts should be available in all environments). Installation of the corresponding Chinese fonts can be resolved.
Big database Bad font environment is not uncommon, the last time in the Win7 Domino, a lot of software fonts have been done, reload the system of Chinese fonts restart the computer to return to normal.


9, Data set preview when the Chinese garbled (full question mark):

Garbled in several cases: one is the box, this is the reason for the font, can not draw the Chinese characters. One is a question mark, this is the problem of coding, such as the MySQL database default encoding is latin1, the library does not have the corresponding encoding in Chinese, can not resolve the Chinese, the solution is to change the code, such as the MySQL code into UTF8 or GBK. Here to note that the database has server code, client-side code, a specific database and a specific table also has code, only in the construction of the database when the table was selected to encode the line (the default is not selected words).


(iii)

1. Repeated column width is Largerthan paper width:

This should be a good understanding of this passage. For example, to do the template page width can only release 5 columns, the result of 6 columns do repeat and freeze, this logic is certainly not justified.

2, the template is not open, Access denied:

It is possible that the Win7 operating system has permissions on the file.

3, the installation of the designer can not preview the report (404 error):

Add servlet tags to the web.xml, with the following specific code:

<servlet>

<servlet-name>ReportServer</servlet-name>

<servlet-class>com.fr.web.ReportServlet</servlet-class>

<load-on-startup>0</load-on-startup>

</servlet>

<servlet-mapping>

<servlet-name>ReportServer</servlet-name>

<url-pattern>/ReportServer</url-pattern>

</servlet-mapping>

4, the object does not support this property or method, XXX is not defined:

Unified page encoding and JS encoding (in the report is the server code), such as page encoding for Utf-8, and the server code for GBK, unified coding method has three, the following we look at a specific setting. Modify the management platform code to match the page code, open the FR management platform, under the management System > System Management > General properties, modify the server-side code as UTF-8, the following figure:




5, date comparison caused an error:

I'm testing my own sqlserver2005.2012/01/01. This format of the date and FR on the 2012-01-01 This format is not comparable, directly from the database read the date format is relatively long, not only the year and year, and can not read, do not know why, As you can see in the preview. And then I added a left in the conditional attribute (ToDate ($$$), 10) to transform a bit to solve, todate transformed into a-connection, the first 10 is the month and a day.



6. Row height inconsistency from one cell (fill preview):

However, page previews are not a problem. The last discovery was made because the data dictionary was set. Set the data dictionary cell its true value row can not be displayed, the line is changed, so widened. Is it a real value calculation when you need space to fill out a preview? The solution, the attention point, pulls the width point to be good.



7. The Custom data dictionary displays the equal sign question:

Finereport like a custom data dictionary this place, with the cell also has hints to define the box, if not the ' = ' number at the beginning is treated as a string, the ' = ' number at the beginning as a formula processing. So it is blank to write an equal sign. Displays the equals sign with = "="



8, a cell content too much error:

Temporary workaround, combining multiple cells directly can increase the input content.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.