Pencils Down

This weblog is about my experiences in software development

Browsing Posts tagged Oracle

After trying several SQL statement queries I stumbled upon a built-in editor for CLOBs in SQL Developer:

  1. SELECT the affected table record(s)
  2. Double click on the column in the row you want to change
  3. Should see a pencil icon on the right hand side of the field
  4. Click on the pencil icon
  5. Should bring up clob in text editor
  6. Make changes
  7. Hit OK
  8. Hit Commit icon


Yet another Oracle error.  However, in this case it is accurately described.

Ran into this with HQL where clause something like:

where =

One of the id’s was numeric, the other was a string.  Had made the silly assumption that PK’s would all be nice integers.

This is a wonderful error message that probably has nothing to do with right parenthesis.  You have probably seen this as a result of some Hibernate coding and wondering how on earth you can have Hibernate generate code with missing parens!

The error really means you have an ORDER BY clause in a subquery.  Oracle can not do this.  The best you can achieve is the use of a WHERE ROWNUM=n clause in the subquery, but any ordering makes Oracle lose it’s mind.

There are theoretical reasons for this which won’t help you get your job done.  Just have to live with the limitation in Oracle.

We are going through what should be a simple exercise to incorporate SSL connectivity to an Oracle database.  If you have not had the pleasure – please avoid this at all costs and let a Oracle DBA do the work.

Think back to late 1970’s IBM configuration files when you needed to change the O/S.  There are real corrollaries here.  You have to change all these (x.ora) config files manually and then use the secret handshake to be logged in as the oracle admin and use the special network configuration tool to see if you can really connect with the changes you just made.  Only then can you use some actual code to connect to the db.

On top of that is this wierd business about Oracle listeners.  There is the Oracle databases – which everyone understands.  But you need a set of Oracle listeners connected to a database in a specific pattern in order to actually access the database.  What a hack.

Even MySql can be configured in a muchcleaner and clearer fashion.  How are they getting away with their pricing model?

This is a really ugly exception thrown by Oracle from the bowels of Hibernate. In my case I had just added a table to the mapping so I at least had some idea where to look.

Looking at the integer values in the table I went through and verified each as correct in the db, mapping, entity and sequence. No luck there.

Poking around the internet though told me the error probably had nothing to do with a LONG mapping and could be ANY size mapping on any field. It’s a generic sizing error.

Luckily the table I created only had a few fields so I was able to narrow done the problem pretty quickly. In my case a VARCHAR2(4000) was attempted to be stored with much more. So, the String in the Java entity had to be controlled to make sure it was small enough.

It’s not much, but thought I would pass the info along and maybe save you some time.