We experience the problem that the object-browser's content-tab in SQuirreL stays blank, if a table contains columns whose names contain non standard characters.
For example column-name test-1. The dash is an invalid character.
The db-engine reports an error within the driver log complaining test is not a column of the table. It stops parsing at location of the dash presumably interpreting the dash as a "minus arithmetic operator".
For most databases this situation is solved by surrounding the
column-name by quotes as in "test-1".
By analysing the problem and looking into the log files I discovered-
that SQuirreL actually
generates a SELECT-Statement (for display within the Content-Tab within the Object-Browser) without surrounding the column-name(s) by
quotes if the column-names contain invalid characters. That is why the
content-tab does not show any data.
The problem can be reproduced easily using the following steps (in my
case with HSQL-DB):
Execute the following statements within the SQL-Worksheet:
create table test ( "test-1" char(10) )
insert into test values ('1111111111')
SELECT test-1 FROM "PUBLIC"."TEST"; --> won't work (which is correct)
SELECT "test-1" FROM "PUBLIC"."TEST" --> will work
Swap to the Object-Browser and select the table test.
Then try to display the data by selecting the Content-Tab:
Content-Tab stays empty.
I consider this a bug in SQuirreL. It should double-quote columns
containing invalid characters when generating
the SELECT-Statement for the contents tab.
Fixed in our Git repository. Will be available in future versions and snapshots.