Package ke.go.moh.oec.reception.controller.exceptions

Examples of ke.go.moh.oec.reception.controller.exceptions.TableCreationException


            statement.execute("CREATE TABLE " + userTable + "(username VARCHAR(50) NOT NULL,"
                    + "password VARCHAR(50) NOT NULL, admin SMALLINT, PRIMARY KEY(username))");
        } catch (SQLException ex) {
            if (!ex.getSQLState().equalsIgnoreCase("X0Y32")) {
                Logger.getLogger(PersistenceManager.class.getName()).log(Level.SEVERE, null, ex);
                throw new TableCreationException(ex.getMessage());
            }
        } finally {
            this.close(statement);
        }
    }
View Full Code Here


            statement.execute("CREATE TABLE " + departmentTable + "(name VARCHAR(50) NOT NULL,"
                    + "code VARCHAR(50) NOT NULL, PRIMARY KEY(name))");
        } catch (SQLException ex) {
            if (!ex.getSQLState().equalsIgnoreCase("X0Y32")) {
                Logger.getLogger(PersistenceManager.class.getName()).log(Level.SEVERE, null, ex);
                throw new TableCreationException(ex.getMessage());
            }
        } finally {
            this.close(statement);
        }
    }
View Full Code Here

TOP

Related Classes of ke.go.moh.oec.reception.controller.exceptions.TableCreationException

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.