#778 "Make Editable" uses column label instead of name

DB2 Plugin (16)

I use Squirrel with IBM DB2 on z/OS, connecting with the "Universal Driver".
Sometimes, column labels differ from the real column names.
When I want to update data changed with the context menu command "Make Editable", I get an error message that a column of that name does not exist.

- ColumnName: MY_TEXTFIELD
- ColumnLabel: MY-TEXT
- Error message wnen updating that says that column MY-TEXT does not exist

That happens with version 2.5 as well as 3.0.1.

IBM DB2 z/OS v8

Classname com.ibm.db2.jcc.DB2Driver
getDriverName: IBM DB2 JDBC Universal Driver Architecture
getDriverVersion 2.8.46

The problem seems to be that Squirrel tries to execute an SQL command and uses getColumnLabel instead of getColumnName.
But is this a matter of a) Squirrel itself, b) the DB2-plugin or c) the specific JDBC driver?

Thank you.


  • Johnathan James

    Johnathan James - 2009-08-04

    Where are you seeing that the column name and column label are different? Is this defined in the database, or are you setting the label of the column in the query?

  • Dirk Schöttler

    Dirk Schöttler - 2009-08-08

    Hello. It is defined in the database. All our table columns have, besides their name, a "DB2 Label" and a "DB2 Comment".

    That name and label are different is shown down on the "Metadata"-tab for any query to the table, after the method name "getColumnLabel" and "getColumnName", see the initial post.

  • Rob Manning

    Rob Manning - 2009-08-08

    Can you tell us how you were able to make the column name and column label different for your tables ? For example, I have DB2 LUW 9.5 fp3.5 installed. When I look at the metadata tab for a result set, the column name and column label are identical. My driver version is 3.53.95. How was the table created ?


  • Dirk Schöttler

    Dirk Schöttler - 2009-08-10

    Hi Rob,

    the data definition looks like this:


    (MY_ID IS 'THE-ID',


  • Nobody/Anonymous

    This is the error code when trying to perform the update by "Make Editable"
    SQLCODE -206
    SQLSTATE: 42703

  • Nobody/Anonymous

    Squirrel has a similar problem when using it with SAS's JDBC driver. It is possible to define columns and not configure a label. Because of this when connecting to a SAS share server and viewing a table you don't see any names for the columns. Many moons ago I hacked the 2.4 source code to show the column name if it was not null or empty as the first choice then fall back to useing the label. I suppose you could make a configuration value somewhere in Squirrel so you could turn that on or off. I never did.

    What are the chances a fix like that might happen? I made my change in the code that lands in FW.jar. too bad I don't remember what class or method I had to change :/.

  • Jim Schneider

    Jim Schneider - 2009-10-08

    This an issue that goes back all the way to version 2.4 atleast. I had this problem when connecting to SAS Share Servers. When defining columns in SAS Datasets the label is optional so you generaly don't have one. Because of this when you view the contents there are no labels for the columns so you don't know what column is what.

    Way back in the day I modified a class that goes in the fw.jar file so that it would use column name first then column label if column name was null or empty. Another issue is that you can have spaces etc in the column labels for SAS.

    Anyway, I don't think I still have the code I changed. It was just a couple of lines. IT would be nice to beable to click a box to say use column name then label or visa versa.

    Thoughts anyone?

  • R. Schmedt

    R. Schmedt - 2009-11-06

    Hello. We also use SQuirreL with IBM DB2 z/OS v9 and know the described problem, too. A workaround would be to label the columns exactly as you name them. However, this is not a good solution.

    Will there be a fix for SQuirreL in the next months?

  • Hugo Sanchón

    Hugo Sanchón - 2009-11-11

    I am also experiencing this problem: our DB2 database uses both column names and labels, and they are different (admin's rules). It's great that squirrel shows column labels when querying the database, but unfortunately it also tries to use them to update a row when using the very convenient "make editable" method

    Does anybody know any hack to overcome this problem?

    If it helps I'd be glad to provide more information about this bug

  • Rob Manning

    Rob Manning - 2010-01-31
    • status: open --> closed-fixed
  • Rob Manning

    Rob Manning - 2010-01-31

    Patch from Christian Gruenberg was just applied in CVS to address this issue. This will go out in the next snapshot and in version 3.1.



Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

JavaScript is required for this form.

No, thanks