|
Compiere 3.1 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.compiere.db.Convert
public class Convert
Convert SQL to Target DB
| Field Summary | |
|---|---|
static int |
REGEX_FLAGS
RegEx: insensitive and dot to include line end characters |
| Constructor Summary | |
|---|---|
Convert(String type)
Cosntructor |
|
| Method Summary | |
|---|---|
String[] |
convert(String sqlStatements)
Convert SQL Statement (stops at first error). |
String |
convertAll(String sqlStatements)
Convert SQL Statement (stops at first error). |
boolean |
execute(String sqlStatements,
Connection conn)
Execute SQL Statement (stops at first error). |
String |
getConversionError()
Return last conversion error or null. |
Exception |
getException()
Return last execution exception |
boolean |
hasError()
Returns true if a conversion or execution error had occured. |
boolean |
isOracle()
Is Oracle DB |
protected String |
removeComments(String statement)
Clean up Statement. |
void |
setVerbose(boolean verbose)
Set Verbose |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public static final int REGEX_FLAGS
| Constructor Detail |
|---|
public Convert(String type)
type - Database.DB_| Method Detail |
|---|
public void setVerbose(boolean verbose)
verbose - public boolean isOracle()
public boolean execute(String sqlStatements,
Connection conn)
sqlStatements - conn - connection
IllegalStateException - if no connectionpublic Exception getException()
public boolean hasError()
public String convertAll(String sqlStatements)
sqlStatements -
public String[] convert(String sqlStatements)
sqlStatements -
public String getConversionError()
protected String removeComments(String statement)
/*ORACLE>*/
Oracle Specific Statement
/*<ORACLE*/
/*POSTGRESQL>
PostgreSQL Specicic Statements
<POSTGRESQL*/
statement -
|
Compiere 3.1 | |||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||