How to SFTP & FTP with Ant Tasks

| Feb 14, 2013

I will explain, how you can send files using ANT scipt over SFTP protocol.

Until i find how to use sftp protocol, I googled also ftp protocol. I will explaint it firstly,

If you want to use FTP protocol, you may use <ftp> tag of commons-net-1.4.1.jar. To do this :

  • Download jar from here.
  • Add this jar to your ant lib folder using explorer or Define it from eclipse, “Window > Preferences > Ant > Runtime > Global Entries > Add Jar “
  • If you do not add this jar, you will get “ (more...)

Making Eclipse IDE Supports JSF 2.0

| Oct 22, 2012

Autocomplete was not working for JSF tags in my Eclipse. I googled it and finally found the solution on

Thanx Mkyong.

The different thing I did is; I downloaded javax.faces-2.xx.xx.jar and saved in a specific folder. Then I created a user library with this jar. I did not use “jsf-api-xxx.jar and jsf-impl-xxx.jar“.

Solution Your profile could not be opened correctly in Chrome

| Nov 3, 2011

When you try to open your chrome web explorer, if you get “Your profile could not be opened correctly” error, try to following solution:
There are several solutions on the web for this, but this is the easiest way:

-Close Chrome
-Go to “C:\Users\[user]\AppData\Local\Google\Chrome\User Data”
-Delete “Web Data” and “Web Data-journal” files. (If you cannot delete it, restart computer)
-Open Chrome

Clear extJS combo value when text is cleared or doesn’t match

| Oct 11, 2011

Here is the scenario;
-Type something to combobox
-Select something on the list
-Search and fill gridPanel
-Clear combobox and then search again
-It fills gridPanel with value that before we cleared.
I this this is a bug.
If you use Ext.getCmp(‘myCombo’).getValue() or Ext.getCmp(‘myCombo’).lastSelectionText, it does not work.
You have to use Ext.getCmp(‘myCombo’).getRawValue(). This works ;)
By the way comboBox is not readonly.

Java Debug Problem “Source not found.”

| May 22, 2011

Quick Hint:
When you try to debug java code in eclipse, if you get “Source not found.” error with red letters. Here is the solution:
Down Arrow Icon Next to Debug Icon > Debug Configurations > Classpath Tab > Add Projects to User Entries
Add your project that cannot debug to this location.

HTML Image Saving Protection (Save Image As >> Point.gif)

| Apr 15, 2011

If you have a web page with full of your copyrighted photos and do not want to visitors to save images in (easy way!) to their local computers. Let me show a trick about it.

In the photo (img) section of the page, we have always something like as following;

     <img id="myImg"
      width="667" height="472"
      style="border-top-width: 0px; border-right-width: 0px; border-bottom-width: 0px; border-left-width: 0px;">

On the image, when we right-click to the mouse and click to “Save Image As” command, we can save the image to our local disk. However, if we create a basic (more...)

C#.Net Download and Merge Images into One Bitmap Image

| Apr 5, 2011

Recently, I developed a program that reads web page for a specific movie and downloads movie info and images. Then, it merges the thumbnails images into one image file.

Firstly, I write the main code, that downloads the image files and merges them and save the merged image to system.

Note 1: In the code, arr variable is an ArrayList holds the picture urls.

Note 2: Image class is in “System.Drawing”

                                        Image[] images = new Image[arr.Length];
                                        for (int k = 0; k < arr.Length; k++){
                                             images[k] = Utils.DownloadImage(arr[k]);
                                        Image mergedImage = Utils.MergeImages(images);

PL/SQL Developer User Preferences (Windows 7)

| Mar 29, 2011

If you changed your computer and want “your PL/SQL developer login history and preferences” as well in your new computer. Copy the following folder to your new computer in the same path format!

C:\Users\[username]\AppData\Roaming\PLSQL Developer

If you need only the login history, open the following file:

C:\Users\[username]\AppData\Roaming\PLSQL Developer\Preferences\[username]\user.prefs

In the file, copy [LogonHistory] part to your new user.prefs file. It’s encrypted but it does not matter. PL/SQL Developer will dencrypt it :)

I need this, because I deal with a lots of database with a lots of schema.. It is really hard to (more...)

ORA-14047: ALTER TABLE|INDEX RENAME may not be combined with other operations

| Mar 21, 2011

When we try to rename  table or index name in Oracle, we use a simple command as following;

alter table [prev_table_name] rename to [last_table_name]

If we put into schema names to this command, we can deal with ORA-14047 error. This error raise when we put schema name in front of the last_table_name.

alter table hr.[prev_table_name] rename to hr.[last_table_name] >>> RAISES ORA-14047 ERROR
alter table hr.[prev_table_name] rename to [last_table_name] >> CORRECT ONE


It is same with Index renaming.

How to remove spaces in a string in Shell

I experienced that when you connect to Oracle database from shell and get some data from the table, if the length of the column value is more than 80 letters. Shell puts space in every 80th letter automaticly. I do not know why, but it is really interesting. I counted the number 80 for my environment. It may differ in different systems.

Anyway, I need to remove that interesting spaces. So here is a script (more...)