| java.lang.Object com.hp.hpl.jena.db.impl.DriverRDB com.hp.hpl.jena.db.impl.Driver_PostgreSQL com.hp.hpl.jena.db.impl.Driver_MsSQL
Driver_MsSQL | public class Driver_MsSQL extends Driver_PostgreSQL (Code) | | This is a driver file for MS SQL Server 2000, MSDE 2000 and
SQL Server 2005 (inc MS SQL Server Express).
There is very little difference from the postgres driver except for the
use of script inheritance to override some of the postgresql SQL commands and
a small difference in the use of ID allocation.
The id allocation approach was adopted from an earlier driver by Erik Barke (eba@ur.se)
N.B. If the postgresql driver file is changed this should be reviewed
for impact.
author: Dave Reynolds version: $Revision: 1.6 $ |
Method Summary | |
public DBIDInt | addRDBLongObject(RDBLongObject lobj, String table) Insert a long object into the database. | protected void | getTblParams(String[] param) Return the parameters for table creation.
1) column type for subj, prop, obj.
2) column type for head.
3) table and index name prefix.
Parameters: param - array to hold table creation parameters. | public int | graphIdAlloc(String graphName) Allocate an identifier for a new graph. | public void | setConnection(IDBConnection dbcon) |
DEFAULT_SQL | final protected static String DEFAULT_SQL(Code) | | Default SQL file from which this driver inherits base operations
|
Driver_MsSQL | public Driver_MsSQL()(Code) | | Constructor. Sets up all the interesting parameters.
|
addRDBLongObject | public DBIDInt addRDBLongObject(RDBLongObject lobj, String table) throws RDFRDBException(Code) | | Insert a long object into the database.
This assumes the object is not already in the database.
Almost a clone of the standard code in Driver_RDB but
returns the ID from the insert instead of from a separate call.
the db index of the added literal |
getTblParams | protected void getTblParams(String[] param)(Code) | | Return the parameters for table creation.
1) column type for subj, prop, obj.
2) column type for head.
3) table and index name prefix.
Parameters: param - array to hold table creation parameters. |
graphIdAlloc | public int graphIdAlloc(String graphName)(Code) | | Allocate an identifier for a new graph.
|
Methods inherited from com.hp.hpl.jena.db.impl.DriverRDB | public boolean DBisLocked() throws RDFRDBException(Code)(Java Doc) protected String IDtoBlank(String bnID)(Code)(Java Doc) protected String IDtoLiteral(int litID)(Code)(Java Doc) protected RDBLongObject IDtoLongObject(int dbid, String table)(Code)(Java Doc) protected RDBLongObject IDtoLongObject(String idAsString, String table)(Code)(Java Doc) protected String IDtoPrefix(int prefixID)(Code)(Java Doc) protected String IDtoString(String dbidAsString, String table, String RDBcode)(Code)(Java Doc) protected String IDtoString(int dbID, String table, String RDBcode)(Code)(Java Doc) protected String IDtoURI(String uriID)(Code)(Java Doc) protected RDBLongObject PrefixToLongObject(String prefix, int split)(Code)(Java Doc) protected Node RDBLiteralStringToLiteralNode(String RDBString, int len, String valType, int pos)(Code)(Java Doc) protected void RDBStringParseInt(String RDBString, ParseInt pi, boolean toEnd)(Code)(Java Doc) public Node RDBStringToNode(String RDBString) throws RDFRDBException(Code)(Java Doc) protected RDBLongObject URIToLongObject(String qname, String code)(Code)(Java Doc) DBIDInt URItoPrefix(String uri, int pos, boolean add)(Code)(Java Doc) public synchronized void abort() throws RDFRDBException(Code)(Java Doc) public String addEscape(String strToMatch)(Code)(Java Doc) public DBIDInt addRDBLongObject(RDBLongObject lobj, String table) throws RDFRDBException(Code)(Java Doc) protected String aliasToString(int alias)(Code)(Java Doc) public synchronized void begin() throws RDFRDBException(Code)(Java Doc) protected void checkDbIsOpen()(Code)(Java Doc) protected void checkDbUninitialized()(Code)(Java Doc) public void cleanDB()(Code)(Java Doc) public void clearSequences()(Code)(Java Doc) public void close() throws RDFRDBException(Code)(Java Doc) protected String colAliasToString(int alias, char colid)(Code)(Java Doc) protected String colidToColname(char colid)(Code)(Java Doc) public void commit() throws RDFRDBException(Code)(Java Doc) protected Node createLiteral(String val, String lang, String dtype)(Code)(Java Doc) public List createSpecializedGraphs(String graphName, Graph requestedProperties)(Code)(Java Doc) public String createTable(int graphId, boolean isReif)(Code)(Java Doc) protected boolean dbIsOpen()(Code)(Java Doc) public static int dbSplitNamespace(String uri)(Code)(Java Doc) public void deleteTable(String tableName)(Code)(Java Doc) protected void doCleanDB(boolean dropMutex) throws RDFRDBException(Code)(Java Doc) protected SpecializedGraph formatAndConstructSystemSpecializedGraph()(Code)(Java Doc) public void formatDB() throws RDFRDBException(Code)(Java Doc) public String genSQLEscapeKW()(Code)(Java Doc) public String genSQLFromKW()(Code)(Java Doc) public String genSQLFromList(int aliasCnt, String table)(Code)(Java Doc) public String genSQLJoin(int lhsAlias, char lhsCol, int rhsAlias, char rhsCol)(Code)(Java Doc) public String genSQLLikeKW()(Code)(Java Doc) public String genSQLOrKW()(Code)(Java Doc) public String genSQLQualConst(int alias, char pred, Node lit)(Code)(Java Doc) public String genSQLQualGraphId(int alias, int graphId)(Code)(Java Doc) public String genSQLQualParam(int alias, char pred)(Code)(Java Doc) public String genSQLReifQualAnyObj(boolean objIsStmt)(Code)(Java Doc) public String genSQLReifQualConst(int alias, char pred, Node lit)(Code)(Java Doc) public String genSQLReifQualObj(char reifProp, boolean hasObj)(Code)(Java Doc) public String genSQLReifQualStmt()(Code)(Java Doc) public String genSQLResList(int resIndex, VarDesc[] binding)(Code)(Java Doc) public String genSQLSelectKW()(Code)(Java Doc) public String genSQLSelectStmt(String res, String from, String qual)(Code)(Java Doc) public String genSQLStringMatch(int alias, char col, String fun, String stringToMatch)(Code)(Java Doc) public String genSQLStringMatchEscape()(Code)(Java Doc) public String genSQLStringMatchLHS(boolean ignCase, String var)(Code)(Java Doc) public String genSQLStringMatchLHS_IC(String var)(Code)(Java Doc) public String genSQLStringMatchLong()(Code)(Java Doc) public String genSQLStringMatchOp(boolean ignCase, String fun)(Code)(Java Doc) public String genSQLStringMatchOp(String fun)(Code)(Java Doc) public String genSQLStringMatchOp_IC(String fun)(Code)(Java Doc) public String genSQLStringMatchRHS(boolean ignCase, boolean pfxMatch, String strToMatch)(Code)(Java Doc) public String genSQLStringMatchRHS_IC(String strToMatch)(Code)(Java Doc) public String genSQLWhereKW()(Code)(Java Doc) protected String genTableName(int graphId, int tblId, boolean isReif)(Code)(Java Doc) protected List getAllTables()(Code)(Java Doc) public DBIDInt getBlankID(String bstr, boolean add) throws RDFRDBException(Code)(Java Doc) public int getCompressCacheSize()(Code)(Java Doc) public int getCompressURILength()(Code)(Java Doc) public IDBConnection getConnection()(Code)(Java Doc) abstract String[] getCreateTableParams(int graphId, boolean isReif)(Code)(Java Doc) public String getDatabaseType()(Code)(Java Doc) abstract String[] getDbInitTablesParams()(Code)(Java Doc) public DBPropGraph getDefaultModelProperties()(Code)(Java Doc) public boolean getDoCompressURI()(Code)(Java Doc) public boolean getDoDuplicateCheck()(Code)(Java Doc) public int getIndexKeyLength()(Code)(Java Doc) public int getIndexKeyLengthMax()(Code)(Java Doc) public int getInsertID(String tableName)(Code)(Java Doc) public boolean getIsTransactionDb()(Code)(Java Doc) public DBIDInt getLiteralID(Node_Literal lnode, boolean add) throws RDFRDBException(Code)(Java Doc) public DBIDInt getLongObjectID(RDBLongObject lobj, String table, boolean add) throws RDFRDBException(Code)(Java Doc) public int getLongObjectLength()(Code)(Java Doc) public int getLongObjectLengthMax()(Code)(Java Doc) public List getSequences()(Code)(Java Doc) public String getStoreWithModel()(Code)(Java Doc) public SpecializedGraph getSystemSpecializedGraph(boolean doInit)(Code)(Java Doc) public int getSystemTableCount()(Code)(Java Doc) public String getSystemTableName(int i)(Code)(Java Doc) protected int getTableCount(int graphId)(Code)(Java Doc) public String getTableNamePrefix()(Code)(Java Doc) public DBIDInt getURIID(String qname, boolean add) throws RDFRDBException(Code)(Java Doc) abstract public int graphIdAlloc(String graphName)(Code)(Java Doc) public boolean isDBFormatOK() throws RDFRDBException(Code)(Java Doc) public String litLangTypeToRDBString(String lang, String dtype) throws RDFRDBException(Code)(Java Doc) protected RDBLongObject literalToLongObject(Node_Literal node)(Code)(Java Doc) public void lockDB() throws RDFRDBException(Code)(Java Doc) public String nodeToRDBString(Node node, boolean addIfLong) throws RDFRDBException(Code)(Java Doc) protected boolean objectIsLong(int encodingLen, String objAsString)(Code)(Java Doc) public List recreateSpecializedGraphs(DBPropGraph graphProperties)(Code)(Java Doc) public void removeSequence(String seqName)(Code)(Java Doc) public void removeSpecializedGraphs(DBPropGraph graphProperties, List specializedGraphs)(Code)(Java Doc) public boolean sequenceExists(String seqName)(Code)(Java Doc) public void setCompressCacheSize(int count)(Code)(Java Doc) public void setCompressURILength(int len)(Code)(Java Doc) public void setDatabaseProperties(Graph databaseProperties)(Code)(Java Doc) public void setDoCompressURI(boolean bool)(Code)(Java Doc) public void setDoDuplicateCheck(boolean bool)(Code)(Java Doc) public void setIndexKeyLength(int len)(Code)(Java Doc) public void setIsTransactionDb(boolean bool)(Code)(Java Doc) protected void setLongObjectHashAndTail(PreparedStatement ps, int argi, RDBLongObject lobj) throws SQLException(Code)(Java Doc) protected void setLongObjectHashAndTail_Binary(PreparedStatement ps, int argi, RDBLongObject lobj) throws SQLException(Code)(Java Doc) protected void setLongObjectHashAndTail_Text(PreparedStatement ps, int argi, RDBLongObject lobj) throws SQLException(Code)(Java Doc) public void setLongObjectLength(int len)(Code)(Java Doc) public void setStoreWithModel(String modelName)(Code)(Java Doc) public void setTableNamePrefix(String prefix)(Code)(Java Doc) protected void setTableNames(String prefix)(Code)(Java Doc) public String stringMatchAllChar()(Code)(Java Doc) public String stringMatchAnyChar()(Code)(Java Doc) public String stringMatchEscapeChar()(Code)(Java Doc) public String stringMatchLongObj()(Code)(Java Doc) public boolean stringMatchNeedsEscape(String strToMatch)(Code)(Java Doc) public String stringMatchShortObj()(Code)(Java Doc) public String stringToDBname(String aName)(Code)(Java Doc) protected long stringToHash(String str)(Code)(Java Doc) public boolean supportsJenaReification()(Code)(Java Doc) public boolean supportsMultipleModels()(Code)(Java Doc) public boolean transactionsSupported()(Code)(Java Doc) public boolean tryLockDB()(Code)(Java Doc) public void unlockDB() throws RDFRDBException(Code)(Java Doc) public DBIDInt wrapDBID(Object id) throws RDFRDBException(Code)(Java Doc) protected synchronized boolean xactOp(int op) throws RDFRDBException(Code)(Java Doc)
|
|
|