Unanswered: JDBC problems in getConnection: Column (site) not found
I'm trying to connect to a informix db using jdbc, and I don't understand what is wrong. This is my connection string:
Connection conn = DriverManager.getConnection("jdbc:informix-sqli://10.1.4.158:11111:INFORMIXSERVER=cms;database=cms;u ser=usercms;password=pwdcms");
When I try to connect, I got the following error on the previous instruction:
java.sql.SQLException: Column (site) not found in any table in the query (or SLV is undefined).
Anybody could help me please?
I quite don't know where could be the error, because all data should be correct, and I have no error in server log.
Thanks for help Tyveleyn, but neither that connection string works, and I got the same error
I'm sure that database name is correct, because if I rename database file (cms.dbs) on server, I got error "database not found or no system permission"
I noticed a strange behaviour by INFORMIXSERVER variable: I thought it defined only the hostname, but if I change it from:
INFORMIXSERVER=cms -> INFORMIXSERVER=only_for_test
I got no errors; so my question is: is an important variable?
I ask this because when informix has been installed, the hostname was different; then we have to change it for network reason, and we replace hostname in solaris config files, in informix config file and in environment variables.
There could be any references to old name written in any binary files or so on, which cause the problem?
Hi, what type of database do you have? Because with the multi-user versions I'm acquainted with the database parameter should not address a database file but the name of a database that is managed by the databaseserver and therefore is a logical name, not a physical one.
The INFORMIXSERVER parameter should reflect the name of the databaseserver, that has nothing to do with the hostname. The name of the databaseserver can be obtained from the DBSERVERNAME or DBSERVERALIASES parameters in the IDS configuration file, which on Solaris should be $INFORMIXDIR/etc/$ONCONFIG. Check it out with:
And it's one of the major importance variables because over a network with this the client connect utility addresses the databaseserver it's looking for, as well as 'native' tools as dbaccess, SQL-Editor or whatever.
If this databaseserver has a listener on the specfied service (port-number) it will respond to calls made by the client.
Ok, I think you have found the main problem..
Informix server has been installed automatically by Avaya CMS, so probably informix standard configuration files are missing: there are no files called onconfig* (or something like that) in $INFORMIXDIR/etc
There were neither a client listening on port (I have created one adding row in sqlhosts and in /etc/services/)
Could you please send me the content of file onconfig.std so I could create it on my server?
Thanks a lot
OK, here it is, the attachment is an onconfig.std file of an IDS 10.0 Express edition. But what puzzles me is if you can get the server on-line right now and how. Because if you can there may be an alternative way to connect to the server by JDBC. I'm not familiar with Avaya CMS so I have absolutely no clue to what kind of magic it's capable of...