I have two auxiliary DB's connected via my oesql.properties. Cross DB selects are working fine, however I wish to use the same connection for writing to catalogs however I recieve the following error message:
Error code -210055, SQL state HY000: [DataDirect][OpenEdge JDBC Driver][OpenEdge] operation not allowed on the read-only database (7842)
Writes to the primary DB have no issue and work as expected.
I am using OE 10.1C04
The PDF documentation has no indication that auxiliary DB's are read-only with the only hint against the DISCONNECT CATALOG statement with the following phrase:
Use the DISCONNECT CATALOG statement to remove a connection from an auxiliary read-only database.
- OpenEdge Data Management: SQL Development - (9-9)
My oesql.properties file is listed as follows:
[sql-configuration]
configuration-names-list=all
[configuration.all]
database-id-list=cu, cm
[database.cu]
Name=cu
Catalog=cu
Location=/data/mfgpro/au/db/cu
[database.cm]
Name=cm
Catalog=cm
Location=/data/mfgpro/cm/db/cm
Hi Brett,
If your application is writing to a db via JDBC that db has to be the primary database. An auxiliary db is always read-only, as described in the OE SQL Reference manual (for Connect stmt).
If your application is writing to only one db in a transaction, then that db has to be the primary db. This enables sql to have transaction integrity without the complexities and overheads of distributed transactions. If different transactions need to write to differing db's, you might consider using multiple connections, which will have separate transactions, of course.
The requirement to have transaction integrity (those so-called ACID properties), in an ordinary transaction, really means that only the primary db can be written to.
If your application has to write to 2 db's in a single transaction, then it needs distributed transaction support (for integrity). In this case, the application can use JTA support. JTA is described in the OE Sql Development book, or many other sql books.JTA lets you write to multiple databases with full integrity.]
hope this helps, ....steve pittman {OE sql software architect]