Friday, May 14, 2010
Thursday, September 24, 2009
Content Assist (Ctrl+Space) stopped working in eclipse 3.5
Friday, May 18, 2007
Java Generics has been around since Java version 1.5 but I have not been using it quite much yet due to the fact "Generified code" can only run under version 1.5 JVM onward. With the requirements to maintain earlier JVM support, we have intentionly stayed away from the Generics. However new code created for Java 1.5 or onward JVM, should start to use Generics for type safe collection etc. More information can be found: java.sun.com website.
Sunday, February 04, 2007
Configure MySQL JDBC Datasource in Tomcat 5.5
Found the instructions posted on Tomcat JNDI Datasource HOW-TO does not work for me. The datasource initialized does not have any reference to the parameters confgured through ResourceParams element. Labels: Java
After searching through vast amount of posts on TheServerSide I found these steps to be the simplest ones.
1. Make sure MySQL JDBC driver jar file such as "mysql-connector-java-3.1.14-bin.jar" is in the
There should be no other version of the MySQL JDBC driver in neither this directory not WEB-INF/lib directory.
2. Update the web application context definition in $TOMCAT_HOME/conf/server.xml
<Context path="/testApp" reloadable="true" docBase="D:\testApp\webapp" workDir="D:\testApp\work">
Do not include the FACTORY attribute as instructed as JNDI Datasource HOW-TO, this is automatically picked up by tomcat 5.5 based on the type of datasource, which here is java.sql.Datasource. Therefore it automatically uses the Tomcat internal dbcp factory.
3. Restart the Tomcat, that's it.
4. Now in your code you should be able to look the connection pool like this:
Context initContext = new InitialContext();
DataSource ds = (DataSource)envContext.lookup("java:/comp/env/jdbc/MySQLDB");
Connection conn = ds.getConnection();
Saturday, January 27, 2007
XAMPP is a software bundle created by www.apachefriends.org which includes everything you need to install Apache/MySQL/PHP/Perl in one go. It is available for Windows, Linux and Solaris. Particularly on a Windows machine, this is definitely the fastest way to get up and running with these tools, as someone else has done the integration and DEFAULT configuration work for you.
The philosophy behind XAMPP is to build an easy to install distribution for developers to get into the world of Apache, PHP and MySQL. To make it convenient for developers XAMPP is configured with all features turned on. The default configuration is not good from a security point of view and it is not secure enough for a production environment. Since v0.9.5 you can make your XAMPP installation securer by calling "security" from XAMPP admin web interface, from which you can tighten up the loose ends.
Tuesday, January 23, 2007
Change Data Range For Existing PivotTables
Say you have a existing PivotTable in Microsoft Excel Speadsheet to summarize the number of accounts in a list of banks. If you change the values in the data source, you need to Refresh the PivotTable and PivotChart to bring the updates from the data source. However these changes are updated only for the data values fallen within the original data range when the PivotTable was initially created. For instance, you have a table with these values:
Based on this data source, you have created a simple pivotTable like this one:
Now add an extra row in the data source table, and refresh pivotTable, you will find the pivotTable is not updated. Why? The reason is that the data range is set to "Sheet1!$A$1:$B$5" when you first created the pivotTable. It is not obvious how can one change the data range in the pivotTable. Right clicking the pivotTable does not give you any options, nor do the menu items.
The trick is to re-enter the PivotTable wizard from the existing pivotTable. The Wizard shows the step 3 of 3 like this:
You need to go back one step to step 2 of 3, like:
From there you can update the data range to "Sheet1!$A$1:$B$6" to include newly added data row, such as this:
Now you can finish the wizard, voilà, the pivotTable is updated with newly added data row included:-)
For more Excel tips visit: MrExcel...
Labels: Excel Tips
In one of my recent projects, I have used Backbase AJAX Framework for JSF to create rich user interface for an B2B telco ebilling application. Backbase AJAX platform consists of a client-side AJAX Engine, JSF Runtime, JSF Components (UI Widgets) and a Developer Tools.
The Backbase JSF runtime performs the AJAX component rendering in the JSF presentation framework. It extends the JSF request lifecycle to work in a Single Page Interface environment, it synchronizes client-server state and facilitates data binding.
The Backbase AJAX JSF Components includes over 30 customizable UI components with built-in AJAX features.
The Backbase AJAX Developer Tools provide a complete set of development tools with a plug-in for the Eclipse platform and debugging tools within the web browser itself.
It offers a 30-day trial version which contains the full functionality.