com.holonplatform.datastore.jdbc.composer.internal

## Class SQLExceptionHelper

- java.lang.Object
- - com.holonplatform.datastore.jdbc.composer.internal.SQLExceptionHelper

-     public class SQLExceptionHelper
      extends Object

  `SQLException` codes extraction helper.
  Since:
    5.2.0

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `SQLExceptionHelper()`

  - ### Method Summary

    All Methods Static Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `static int` | `getErrorCode(SQLException sqlException)` Get the vendor-specific error code.
    `static Optional<String>` | `getSqlState(SQLException sqlException)` Get the SQL state.

    - ### Methods inherited from class java.lang.Object

      `equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### SQLExceptionHelper

          public SQLExceptionHelper()

  - ### Method Detail

    - #### getErrorCode

          public static int getErrorCode(SQLException sqlException)

      Get the vendor-specific error code.
      Parameters:
        `sqlException` - The exception from which to extract the code
      Returns:
        The error code

    - #### getSqlState

          public static Optional<String> getSqlState(SQLException sqlException)

      Get the SQL state.
      Parameters:
        `sqlException` - The exception from which to extract the state
      Returns:
        Optional SQL state

Copyright © 2019 The Holon Platform. All rights reserved.