Subject Re: [Firebird-Java] Invalid clumplet Buffer Structure
Author Roman Rokytskyy
Hi,

> I was wondering what the best mechanism to work with exceptions
> between Java and Firebird is. I am throwing an exception in Firebird
> inside a trigger, and I would like to get the message in Java. What I
> get is the whole message from Firebird. What I need to extract is the
> message I created for the stored procedure. For instance, let's I have
> declared the following exception:
>
> create exception belowzero 'Value is below zero';
>
> How do I get just the 'Value is below zero' string from java?

At the moment it is possible only by using following code:

import org.firebirdsql.gds.GDSException;
import org.firebirdsql.jdbc.FBException;
...
GDSException gdsException =
((FBException)sqlException).getInternalException();

and then navigate via gdsException list, which corresponds the normal
status vector from API reference.

Please register a feature request in the tracker to handle this
situation better.

Roman