Tuesday, July 6, 2010

Two trivial Issues

Today I stumbled upon two "insignificant" issues which I have faced before but it took reasonable amount of time to "re-discover" the solution. One good way of "not forgetting" quick solution to known problems is blogging about them.

Issue #1
After generating the JAX RPC client artifacts for consuming a service I was getting an error: java.lang.UnsupportedClassVersionError. This exception can occur when the source is built targeting a JDK(in my case JDK 1.5) that is not supported by the JDK(JDK 1.4) attempting to run it.
I simply added one attribute 'source = "1.4"' in the <javac> tag of the ant script which is used to generate and compile the artifacts and that solved the problem.

Issue #2
I am using CCRC 7.1 as the source control tool for my project.
I was having a perfect eclipse workspace and suddenly one of the project module started complaining :
'Internal error - the selected file is a system file that cannot be modified. It will be hidden.'
It does appear because it automatically copies the CCRC internal file .copyarea.db in the bin (build target) directory which confuses the build process.
The solution:
1. In Window-> Preferences menu, go to Java -> Compiler -> Building item.
2. Expand the Output folder and add .copyarea.db to the Filtered Resources of the output folder. My edit field looked like this: *.launch, .copyarea.db
3. Remove the .copyarea.db files from your java build output directories such as /<project>/bin/ and /<project>/build.
4. Refresh and rebuild each project that is displaying this error.

Now we can talk about productivity :)

Wednesday, May 19, 2010

Select trigger in Oracle DB using Fine Grained Auditing.

Well, as it goes that triggers can only be written on DML and never on select statements: very true but it seems like using "Fine Grained Auditing" functionality of the DBMS_FGA package, it is possible to create trigger like functionality for select statements.
I was searching for similar concepts for a project which requires the count of every row which has been queried be increased. And I stumbled upon this: FGA. Though I didn't quite use this and did a work around but it sounds fun.

Friday, January 15, 2010

Surya Grahan

For the first time in my life, I saw a solar eclipse with a goggles today.
It was, in one word, awesome. The corona was looking like a golden ring of fire. I was feeling that if it is not divine revelation then what is. The special things about this eclipse:
1. It is one of the longest duration annular eclipse, the duration of which won't be exceeded in a thousand years(till Dec, 3043).
2. I fasted till the eclipse ended(No, I'm not that religious; just to bring a difference to daily routine)
After the eclipse, I was damn hungry and ate like a glutton.
Being a devoted Einstein fan, I remembered that taken during one of the longest solar eclipse of the 20th century, the British scientist Arthur Stanley Eddington's photographs played a vital role in proving the theory of relativity.