Total Pageviews


Cannot Import Java Source Code via Astah Pro

When I used Astah Pro to do import java code

But it show the error which complain encoding issues:

As we do import java code, we need to set the property of "Charset of imported files" to UTF-8.

Then we can import Java source code successfully.

An internal error occurred during: "Initializing Java Tooling" from Eclipse

One day as I startup my eclipse it show the error as bellows:

Step1. Close Eclipse
Step2. Go to your eclipse workspace, and go to this directory

Step3. delete variablesAndContainers.dat
Step4. Start Eclipse


How to pad a string with spaces when size of data is unknown in Microsoft SQL Server

When I select a character data with varchar(6) from Microsoft SQL Server....

And these data should have fixed length in report.
If the data is 01, it should right pad with 4 spaces.
If the data is 01234, it should right pad with 1 space.

If we would like to meet this requirement in SQL Server, we can use 'CAST' function which provided by SQL Server
select cast(repno as char(6)) from NSS313FA  

Utilizing cast function in SQL statement, you can get fixed length in report no matter how long the data is.


How to display column footer immediately without any spaces after details band

This is my report design in iReport:

Here is the Detail property and Column Footer property setting: I generate pdf, there has unnecessary spaces between Detail band and Column Footer band.

Step1. Right click --> property

Step2. Check the "Float column footer" property

Then this problem will be solved. There will not have any spaces between Detail band and Column Footer band.