class TSQLFile: public TFile

 The main motivation for the TSQLFile development is to have
 "transparent" access to SQL data base via standard TFile interface.

 The main approach that each class (but not each object) has one or two tables
 with names like $(CLASSNAME)_ver$(VERSION) and $(CLASSNAME)_raw$(VERSION)
 For example: TAxis_ver8 or TList_raw5
 Second kind of tables appears, when some of class members can not be converted to
 normalized form or when class has custom streamer.
 For instance, for TH1 class two tables are required: TH1_ver4 and TH1_raw4
 Most of memebers are stored in TH1_ver4 table columnwise, and only memeber:

  Double_t*  fBuffer;  //[fBufferSize]

 can not be represented as column while size of array is not known apriory.
 Therefore, fBuffer will be written as list of values in TH1_raw4 table.

 All objects, stored in the DB, will be registered in table "ObjectsTable".
 In this there are following columns:
     "key:id"  - key identifier to which belong object
     "obj:id"  - object identifier
     "Class"   - object class name
     "Version" - object class version
  Data in each "ObjectsTable" row uniqly identify, in which table
  and which column object is stored.

 In normal situation all class data should be sorted columnwise.
 Up to now following member are supported:
 1) Basic data types
     Here is everything clear. Column SQL type will be as much as possible
     close to the original type of value.
 2) Fixed array of basic data types
     In this case n columns like fArr[0], fArr[1] and so on will be created.
     If there is multidimensional array, names will be fArr2[1][2][1] and so on
 3) Parent class
     In this case version of parent class is stored and
     data of parent class will be stored with the same obj:id in corrspondent table.
     There is a special case, when parent store nothing (this is for instance TQObject).
     In that case just -1 is written to avoid any extra checks if table exist or not.
 4) Object as data member.
     In that case object is saved in normal way to data base and column
     will contain id of this object.
 5) Pointer on object
     Same as before. In case if object was already stored, just its id
     will be placed in the column. For NULL pointer 0 is used.
 6) TString
     Now column with limited width like VARCAHR(255) in MySQL is used.
     Later this will be improved to support maximum possible strings
 7) Anything else.
     Data will be converted to raw format and saved in _streamer_ table.
     Each row supplied with obj:id and row:id, where row:id indicates
     data, corresponding to this particular data member, and column
     will contain this raw:id

 All conversion to SQL statements are done with help of TSQLStructure class.
 This is special hierarchical structure wich internally is very similar
 to XML structures. TBufferSQL2 creates these structures, when object
 data is streamed by ROOT and only afterwards all SQL statements will be produced
 and applied all together.

 When data is reading, TBufferSQL2 will produce requests to database
 during unstreaming of object data.

 Optionally (default this options on) name of column includes
 suffix which indicates type of column. For instance:
   *:parent  - parent class, column contain class version
   *:object  - other object, column contain object id
   *:rawdata - raw data, column contains id of raw data from _streamer_ table
   *:Int_t   - column with integer value
 Use TSQLFile::SetUseSuffixes(kFALSE) to disable suffixes usage.

 This and several other options can be changed only when
 TSQLFile created with options "CREATE" or "RECREATE" and only before
 first write operation. These options are:
     SetUseSuffixes() - suffix usage in column names (default - on)
     SetArrayLimit()  - defines maximum array size, which can
                        has column for each element (default 21)
     SetTablesType()  - table type name in MySQL database (default "InnoDB")
     SetUseIndexes()  - usage of indexes in database (default kIndexesBasic)
 Normally these functions should be called immidiately after TSQLFile constructor.

 When objects data written to database, by default START TRANSACTION/COMMIT
 SQL commands are used before and after data storage. If TSQLFile detects
 any problems, ROLLBACK command will be used to restore
 previous state of data base. If transactions not supported by SQL server,
 they can be disabled by SetUseTransactions(kTransactionsOff). Or user
 can take responsibility to use transactions function to hime

 By default only indexes for basic tables are created.
 In most cases usage of indexes increase perfomance to data reading,
 but it also can increase time of writing data to database.
 There are several modes of index usage available in SetUseIndexes() method

 There is MakeSelectQuery(TClass*) method, which
 produces SELECT statement to get objects data of specified class.
 Difference from simple statement like:
   mysql> SELECT * FROM TH1I_ver1
 that not only data for that class, but also data from parent classes
 will be extracted from other tables and combined in single result table.
 Such select query can be usufull for external access to objects data.

 Up to now MySQL 4.1 and Oracle 9i were tested.
 Some extra work is required for other SQL databases.
 Hopefully, this should be straigthforward.

 Known problems and open questions.
 1) TTree is not supported by TSQLFile. There is independent development
    of TTreeSQL class, which allows to store trees directly in SQL database
 2) TClonesArray is store objects in raw format,
    which can not be accessed outside ROOT.
    This will be changed later.
 3) TDirectory cannot work. Hopefully, will (changes in ROOT basic I/O is required)
 4) Streamer infos are not written to file, therefore schema evolution
    is not yet supported. All eforts are done to enable this feature in
    the near future

 Example how TSQLFile can be used:

 example of a session saving data to a SQL data base

  const char* dbname = "mysql://host.domain:3306/dbname";
  const char* username = "username";
  const char* userpass = "userpass";

  // Clean data base and create primary tables
  TSQLFile* f = new TSQLFile(dbname, "recreate", username, userpass);
  // Write with standard I/O functions
  arr->Write("arr", TObject::kSingleKey);
  // Close connection to DB
  delete f;

 example of a session read data from SQL data base

  // Open database again in read-only mode
  TSQLFile* f = new TSQLFile(dbname, "open", username, userpass);
  // Show list of keys
  // Read stored object, again standard ROOT I/O
  TH1* h1 = (TH1*) f->Get("histo");
  if (h1!=0) { h1->SetDirectory(0); h1->Draw(); }
  TObject* obj = f->Get("arr");
  if (obj!=0) obj->Print("*");
  // close connection to DB
  delete f;

 The "SQL I/O" package is currently under development.
 Any bug reports and suggestions are welcome.
 Author: S.Linev, GSI Darmstadt,

Function Members (Methods)

voidTObject::AbstractMethod(const char* method) const
virtual voidTDirectoryFile::Add(TObject* obj, Bool_t replace = kFALSE)
static voidTDirectory::AddDirectory(Bool_t add = kTRUE)
static Bool_tTDirectory::AddDirectoryStatus()
virtual voidTDirectoryFile::Append(TObject* obj, Bool_t replace = kFALSE)
virtual Int_tTDirectoryFile::AppendKey(TKey* key)
virtual voidTObject::AppendPad(Option_t* option = "")
static TFileOpenHandle*TFile::AsyncOpen(const char* name, Option_t* option = "", const char* ftitle = "", Int_t compress = 1, Int_t netopt = 0)
virtual voidTDirectoryFile::Browse(TBrowser* b)
virtual voidTDirectoryFile::Build(TFile* motherFile = 0, TDirectory* motherDir = 0)
virtual Bool_tTDirectoryFile::cd(const char* path = 0)
static Bool_tTDirectory::Cd(const char* path)
static TClass*Class()
virtual const char*TObject::ClassName() const
virtual voidTDirectory::Clear(Option_t* option = "")
virtual TObject*TNamed::Clone(const char* newname = "") const
virtual TObject*TDirectoryFile::CloneObject(const TObject* obj, Bool_t autoadd = kTRUE)
virtual voidClose(Option_t* option = "")MENU
virtual Int_tTNamed::Compare(const TObject* obj) const
virtual voidTFile::Copy(TObject&) const
virtual Bool_tTFile::Cp(const char* dst, Bool_t progressbar = kTRUE, UInt_t buffersize = 1000000)
static Bool_tTFile::Cp(const char* src, const char* dst, Bool_t progressbar = kTRUE, UInt_t buffersize = 1000000)
virtual TKey*CreateKey(TDirectory* mother, const TObject* obj, const char* name, Int_t bufsize)
virtual TKey*CreateKey(TDirectory* mother, const void* obj, const TClass* cl, const char* name, Int_t bufsize)
static TDirectory*&TDirectory::CurrentDirectory()
static TFile*&TFile::CurrentFile()
static voidTDirectory::DecodeNameCycle(const char* namecycle, char* name, Short_t& cycle, const size_t namesize = 0)
virtual voidTFile::Delete(const char* namecycle = "")
virtual voidTDirectory::DeleteAll(Option_t* option = "")
virtual Int_tTObject::DistancetoPrimitive(Int_t px, Int_t py)
virtual voidTFile::Draw(Option_t* option = "")
virtual voidTObject::DrawClass() constMENU
virtual TObject*TObject::DrawClone(Option_t* option = "") constMENU
virtual voidDrawMap(const char* = "*", Option_t* = "")
virtual voidTObject::Dump() constMENU
static voidTDirectory::EncodeNameCycle(char* buffer, const char* name, Short_t cycle)
virtual voidTObject::Error(const char* method, const char* msgfmt) const
virtual voidTObject::Execute(const char* method, const char* params, Int_t* error = 0)
virtual voidTObject::Execute(TMethod* method, TObjArray* params, Int_t* error = 0)
virtual voidTObject::ExecuteEvent(Int_t event, Int_t px, Int_t py)
virtual voidTObject::Fatal(const char* method, const char* msgfmt) const
virtual voidFillBuffer(char*&)
virtual TKey*TDirectoryFile::FindKey(const char* keyname) const
virtual TKey*TDirectoryFile::FindKeyAny(const char* keyname) const
virtual TObject*TDirectory::FindObject(const char* name) const
virtual TObject*TDirectory::FindObject(const TObject* obj) const
virtual TObject*TDirectoryFile::FindObjectAny(const char* name) const
virtual TObject*TDirectoryFile::FindObjectAnyFile(const char* name) const
virtual voidFlush()
virtual TObject*TDirectoryFile::Get(const char* namecycle)
TArchiveFile*TFile::GetArchive() const
Long64_tTFile::GetArchiveOffset() const
Int_tGetArrayLimit() const
static TFile::EAsyncOpenStatusTFile::GetAsyncOpenStatus(const char* name)
static TFile::EAsyncOpenStatusTFile::GetAsyncOpenStatus(TFileOpenHandle* handle)
Int_tTFile::GetBestBuffer() const
virtual Int_tTDirectoryFile::GetBufferSize() const
virtual Long64_tTFile::GetBytesRead() const
virtual Long64_tTFile::GetBytesReadExtra() const
virtual Int_tTFile::GetBytesToPrefetch() const
virtual Long64_tTFile::GetBytesWritten() const
static const char*TFile::GetCacheFileDir()
TFileCacheRead*TFile::GetCacheRead(TObject* tree = 0) const
TFileCacheWrite*TFile::GetCacheWrite() const
TArrayC*TFile::GetClassIndex() const
Int_tTFile::GetCompressionAlgorithm() const
Int_tTFile::GetCompressionLevel() const
Int_tTFile::GetCompressionSettings() const
const TDatime&TDirectoryFile::GetCreationDate() const
const char*GetDataBaseName() const
virtual TDirectory*TDirectoryFile::GetDirectory(const char* apath, Bool_t printError = false, const char* funcname = "GetDirectory")
virtual Option_t*TObject::GetDrawOption() const
static Long_tTObject::GetDtorOnly()
virtual Long64_tGetEND() const
virtual const TUrl*TFile::GetEndpointUrl() const
static const TUrl*TFile::GetEndpointUrl(const char* name)
virtual Int_tGetErrno() const
Int_tTFile::GetFd() const
virtual TFile*TDirectoryFile::GetFile() const
static Long64_tTFile::GetFileBytesRead()
static Long64_tTFile::GetFileBytesWritten()
static Long64_tTFile::GetFileCounter()
static Int_tTFile::GetFileReadCalls()
virtual const char*TObject::GetIconName() const
virtual TKey*TDirectoryFile::GetKey(const char* name, Short_t cycle = 9999) const
virtual TList*TDirectory::GetList() const
TList*TFile::GetListOfFree() const
virtual TList*TDirectoryFile::GetListOfKeys() const
TObjArray*TFile::GetListOfProcessIDs() const
const TDatime&TDirectoryFile::GetModificationDate() const
virtual TObject*TDirectory::GetMother() const
virtual TDirectory*TDirectory::GetMotherDir() const
virtual const char*TNamed::GetName() const
virtual Int_tGetNbytesFree() const
virtual Int_tGetNbytesInfo() const
virtual Int_tTDirectoryFile::GetNbytesKeys() const
virtual TStringTFile::GetNewUrl()
virtual Int_tGetNfree() const
virtual Int_tTDirectoryFile::GetNkeys() const
virtual Int_tTFile::GetNProcessIDs() const
virtual void*TDirectoryFile::GetObjectChecked(const char* namecycle, const char* classname)
virtual void*TDirectoryFile::GetObjectChecked(const char* namecycle, const TClass* cl)
virtual char*TObject::GetObjectInfo(Int_t px, Int_t py) const
static Bool_tTObject::GetObjectStat()
virtual void*TDirectoryFile::GetObjectUnchecked(const char* namecycle)
static Bool_tTFile::GetOnlyStaged()
static UInt_tTFile::GetOpenTimeout()
virtual Option_t*TFile::GetOption() const
virtual const char*TDirectory::GetPath() const
virtual const char*TDirectory::GetPathStatic() const
Int_tGetQuerisCounter() const
static Int_tTFile::GetReadaheadSize()
virtual Int_tTFile::GetReadCalls() const
static Bool_tTFile::GetReadStreamerInfo()
Int_tTFile::GetRecordHeader(char* buf, Long64_t first, Int_t maxbytes, Int_t& nbytes, Int_t& objlen, Int_t& keylen)
Long64_tTFile::GetRelOffset() const
virtual Long64_tTDirectoryFile::GetSeekDir() const
virtual Long64_tGetSeekFree() const
virtual Long64_tGetSeekInfo() const
virtual Long64_tTDirectoryFile::GetSeekKeys() const
virtual Long64_tTDirectoryFile::GetSeekParent() const
virtual Long64_tGetSize() const
const TList*TFile::GetStreamerInfoCache()
virtual TList*GetStreamerInfoList()
const char*GetTablesType() const
virtual const char*TNamed::GetTitle() const
static TFile::EFileTypeTFile::GetType(const char* name, Option_t* option = "", TString* prefix = 0)
virtual UInt_tTObject::GetUniqueID() const
Int_tGetUseIndexes() const
Bool_tGetUseSuffixes() const
Int_tGetUseTransactions() const
TUUIDTDirectory::GetUUID() const
Int_tTFile::GetVersion() const
virtual Bool_tTObject::HandleTimer(TTimer* timer)
virtual ULong_tTNamed::Hash() const
static voidTFile::IncrementFileCounter()
virtual voidTFile::IncrementProcessIDs()
virtual voidTObject::Info(const char* method, const char* msgfmt) const
virtual Bool_tTObject::InheritsFrom(const char* classname) const
virtual Bool_tTObject::InheritsFrom(const TClass* cl) const
virtual voidTObject::Inspect() constMENU
voidTObject::InvertBit(UInt_t f)
virtual TClass*IsA() const
virtual Bool_tTFile::IsArchive() const
Bool_tTFile::IsBinary() const
virtual Bool_tTObject::IsEqual(const TObject* obj) const
virtual Bool_tTDirectory::IsFolder() const
virtual Bool_tTDirectoryFile::IsModified() const
Bool_tIsMySQL() const
Bool_tIsODBC() const
Bool_tTObject::IsOnHeap() const
virtual Bool_tIsOpen() const
Bool_tIsOracle() const
Bool_tTFile::IsRaw() const
virtual Bool_tTNamed::IsSortable() const
virtual Bool_tTDirectoryFile::IsWritable() const
Bool_tTObject::IsZombie() const
virtual voidTFile::ls(Option_t* option = "") const
virtual voidMakeFree(Long64_t, Long64_t)
virtual voidMakeProject(const char*, const char* = "*", Option_t* = "new")MENU
TStringMakeSelectQuery(TClass* cl)
virtual voidMap()
virtual Bool_tTFile::Matches(const char* name)
voidTObject::MayNotUse(const char* method) const
virtual TDirectory*TDirectoryFile::mkdir(const char* name, const char* title = "")
virtual Bool_tTFile::MustFlush() const
virtual Bool_tTObject::Notify()
voidTObject::Obsolete(const char* method, const char* asOfVers, const char* removedFromVers) const
static TFile*TFile::Open(TFileOpenHandle* handle)
static TFile*TFile::Open(const char* name, Option_t* option = "", const char* ftitle = "", Int_t compress = 1, Int_t netopt = 0)
virtual TFile*TDirectoryFile::OpenFile(const char* name, Option_t* option = "", const char* ftitle = "", Int_t compress = 1, Int_t netopt = 0)
voidTObject::operator delete(void* ptr)
voidTObject::operator delete(void* ptr, void* vp)
voidTObject::operator delete[](void* ptr)
voidTObject::operator delete[](void* ptr, void* vp)
void*TObject::operator new(size_t sz)
void*TObject::operator new(size_t sz, void* vp)
void*TObject::operator new[](size_t sz)
void*TObject::operator new[](size_t sz, void* vp)
virtual voidPaint(Option_t* = "")
virtual voidTObject::Pop()
virtual voidPrint(Option_t* = "") const
virtual voidTDirectoryFile::Purge(Short_t nkeep = 1)
virtual voidTDirectory::pwd() const
virtual Int_tTObject::Read(const char* name)
virtual voidTDirectoryFile::ReadAll(Option_t* option = "")
virtual Bool_tReadBuffer(char*, Int_t)
virtual Bool_tReadBuffer(char*, Long64_t, Int_t)
virtual Bool_tTFile::ReadBufferAsync(Long64_t offs, Int_t len)
virtual Bool_tTFile::ReadBuffers(char* buf, Long64_t* pos, Int_t* len, Int_t nbuf)
virtual voidReadFree()
virtual Int_tTDirectoryFile::ReadKeys(Bool_t forceRead = kTRUE)
virtual TProcessID*TFile::ReadProcessID(UShort_t pidf)
virtual voidTFile::ReadStreamerInfo()
virtual Int_tTDirectoryFile::ReadTObject(TObject* obj, const char* keyname)
virtual Int_tRecover()
virtual voidTDirectory::RecursiveRemove(TObject* obj)
virtual TObject*TDirectory::Remove(TObject*)
virtual Int_tReOpen(Option_t* mode)
virtual voidTDirectoryFile::ResetAfterMerge(TFileMergeInfo*)
voidTObject::ResetBit(UInt_t f)
virtual voidResetErrno() const
virtual voidTDirectoryFile::rmdir(const char* name)
virtual voidTDirectoryFile::Save()
virtual voidTObject::SaveAs(const char* filename = "", Option_t* option = "") constMENU
virtual Int_tTDirectoryFile::SaveObjectAs(const TObject* obj, const char* filename = "", Option_t* option = "") const
virtual voidTObject::SavePrimitive(ostream& out, Option_t* option = "")
virtual voidTDirectoryFile::SaveSelf(Bool_t force = kFALSE)
virtual voidSeek(Long64_t, TFile::ERelativeTo = kBeg)
voidSetArrayLimit(Int_t limit = 20)
voidTObject::SetBit(UInt_t f)
voidTObject::SetBit(UInt_t f, Bool_t set)
virtual voidTDirectoryFile::SetBufferSize(Int_t bufsize)
static Bool_tTFile::SetCacheFileDir(const char* cacheDir, Bool_t operateDisconnected = kTRUE, Bool_t forceCacheread = kFALSE)
virtual voidTFile::SetCacheRead(TFileCacheRead* cache, TObject* tree = 0, TFile::ECacheAction action = kDisconnect)
virtual voidTFile::SetCacheWrite(TFileCacheWrite* cache)
virtual voidTFile::SetCompressionAlgorithm(Int_t algorithm = 0)
virtual voidTFile::SetCompressionLevel(Int_t level = 1)
virtual voidTFile::SetCompressionSettings(Int_t settings = 1)
virtual voidTObject::SetDrawOption(Option_t* option = "")MENU
static voidTObject::SetDtorOnly(void* obj)
virtual voidSetEND(Long64_t)
static voidTFile::SetFileBytesRead(Long64_t bytes = 0)
static voidTFile::SetFileBytesWritten(Long64_t bytes = 0)
static voidTFile::SetFileReadCalls(Int_t readcalls = 0)
virtual voidTDirectoryFile::SetModified()
virtual voidTDirectory::SetMother(TObject* mother)
virtual voidTDirectory::SetName(const char* newname)
virtual voidTNamed::SetNameTitle(const char* name, const char* title)
static voidTObject::SetObjectStat(Bool_t stat)
virtual voidTFile::SetOffset(Long64_t offset, TFile::ERelativeTo pos = kBeg)
static Bool_tTFile::SetOnlyStaged(Bool_t onlystaged)
static UInt_tTFile::SetOpenTimeout(UInt_t timeout)
virtual voidTFile::SetOption(Option_t* option = ">")
static voidTFile::SetReadaheadSize(Int_t bufsize = 256000)
virtual voidTFile::SetReadCalls(Int_t readcalls = 0)
static voidTFile::SetReadStreamerInfo(Bool_t readinfo = kTRUE)
virtual voidTDirectoryFile::SetSeekDir(Long64_t v)
voidSetTablesType(const char* table_type)
virtual voidTNamed::SetTitle(const char* title = "")MENU
virtual voidTDirectoryFile::SetTRefAction(TObject* ref, TObject* parent)
virtual voidTObject::SetUniqueID(UInt_t uid)
voidSetUseIndexes(Int_t use_type = kIndexesBasic)
voidSetUseSuffixes(Bool_t on = kTRUE)
voidSetUseTransactions(Int_t mode = kTransactionsAuto)
virtual voidTDirectoryFile::SetWritable(Bool_t writable = kTRUE)
virtual voidShowMembers(TMemberInspector& insp) const
virtual voidTFile::ShowStreamerInfo()
static Bool_tTFile::ShrinkCacheFileDir(Long64_t shrinkSize, Long_t cleanupInteval = 0)
virtual Int_tSizeof() const
voidStartLogFile(const char* fname)MENU
virtual voidStreamer(TBuffer&)
voidStreamerNVirtual(TBuffer& ClassDef_StreamerNVirtual_b)
voidTFile::SumBuffer(Int_t bufsize)
virtual voidTObject::SysError(const char* method, const char* msgfmt) const
Bool_tTObject::TestBit(UInt_t f) const
Int_tTObject::TestBits(UInt_t f) const
TSQLFile(const TSQLFile&)
TSQLFile(const char* dbname, Option_t* option = "read", const char* user = "user", const char* pass = "pass")
virtual voidTObject::UseCurrentStyle()
virtual voidTObject::Warning(const char* method, const char* msgfmt) const
virtual Int_tWrite(const char* = 0, Int_t = 0, Int_t = 0)
virtual Int_tWrite(const char* = 0, Int_t = 0, Int_t = 0) const
virtual Bool_tWriteBuffer(const char*, Int_t)
virtual voidTDirectoryFile::WriteDirHeader()
virtual voidWriteFree()
virtual voidWriteHeader()
virtual voidTDirectoryFile::WriteKeys()
virtual Int_tTDirectoryFile::WriteObjectAny(const void* obj, const char* classname, const char* name, Option_t* option = "", Int_t bufsize = 0)
virtual Int_tTDirectoryFile::WriteObjectAny(const void* obj, const TClass* cl, const char* name, Option_t* option = "", Int_t bufsize = 0)
virtual UShort_tTFile::WriteProcessID(TProcessID* pid)
virtual voidWriteStreamerInfo()
virtual Int_tTDirectoryFile::WriteTObject(const TObject* obj, const char* name = 0, Option_t* option = "", Int_t bufsize = 0)
voidAddIdEntry(Long64_t tableid, Int_t subid, Int_t type, const char* name, const char* sqlname, const char* info)
Bool_tTDirectory::cd1(const char* path)
static Bool_tTDirectory::Cd1(const char* path)
virtual voidTDirectoryFile::CleanTargets()
TStringCodeLongString(Long64_t objid, Int_t strid)
Bool_tCreateClassTable(TSQLClassInfo* sqlinfo, TObjArray* colinfos)
Bool_tCreateRawTable(TSQLClassInfo* sqlinfo)
TStringDefineTableName(const char* clname, Int_t version, Bool_t rawtable)
voidDeleteKeyFromDB(Long64_t keyid)
virtual Long64_tDirCreateEntry(TDirectory*)
virtual Int_tDirReadKeys(TDirectory*)
virtual voidDirWriteHeader(TDirectory*)
virtual voidDirWriteKeys(TDirectory*)
virtual voidTObject::DoError(int level, const char* location, const char* fmt, va_list va) const
voidTDirectory::FillFullPath(TString& buf) const
TSQLClassInfo*FindSQLClassInfo(const TClass* cl)
TSQLClassInfo*FindSQLClassInfo(const char* clname, Int_t version)
TKeySQL*FindSQLKey(TDirectory* dir, Long64_t keyid)
virtual TFile::EAsyncOpenStatusTFile::GetAsyncOpenStatus()
TSQLResult*GetBlobClassData(Long64_t objid, TSQLClassInfo* sqlinfo)
TSQLStatement*GetBlobClassDataStmt(Long64_t objid, TSQLClassInfo* sqlinfo)
Bool_tGetLongString(Long64_t objid, Int_t strid, TString& value)
TSQLResult*GetNormalClassData(Long64_t objid, TSQLClassInfo* sqlinfo)
TSQLResult*GetNormalClassDataAll(Long64_t minobjid, Long64_t maxobjid, TSQLClassInfo* sqlinfo)
Bool_tHasTable(const char* name)
virtual voidTFile::Init(Bool_t create)
voidInitSqlDatabase(Bool_t create)
Int_tIsLongStringCode(Long64_t objid, const char* value)
Int_tTFile::MakeProjectParMake(const char* packname, const char* filename)
Int_tTFile::MakeProjectParProofInf(const char* packname, const char* proofinfdir)
Bool_tProduceClassSelectQuery(TVirtualStreamerInfo* info, TSQLClassInfo* sqlinfo, TString& columns, TString& tables, Int_t& tablecnt)
Int_tTFile::ReadBufferViaCache(char* buf, Int_t len)
TObject*ReadSpecialObject(Long64_t keyid, TObject* obj = 0)
voidTDirectory::RegisterContext(TDirectory::TContext* ctxt)
TSQLClassInfo*RequestSQLClassInfo(const TClass* cl)
TSQLClassInfo*RequestSQLClassInfo(const char* clname, Int_t version)
voidSetLocking(Int_t mode)
Bool_tSQLApplyCommands(TObjArray* cmds)
const char*SQLBigTextType() const
const char*SQLCompatibleType(Int_t typ) const
const char*SQLDatetimeType() const
const char*SQLDefaultTableType() const
voidSQLDeleteStatement(TSQLStatement* stmt)
const char*SQLDirIdColumn() const
const char*SQLIdentifierQuote() const
const char*SQLIntType() const
const char*SQLKeyIdColumn() const
Long64_tSQLMaximumValue(const char* tablename, const char* columnname)
const char*SQLNameSeparator() const
const char*SQLObjectIdColumn() const
Bool_tSQLObjectInfo(Long64_t objid, TString& clname, Version_t& version)
TObjArray*SQLObjectsInfo(Long64_t keyid)
TSQLResult*SQLQuery(const char* cmd, Int_t flag = 0, Bool_t* res = 0)
const char*SQLRawIdColumn() const
const char*SQLSmallTextType() const
Int_tSQLSmallTextTypeLimit() const
TSQLStatement*SQLStatement(const char* cmd, Int_t bufsize = 1000)
const char*SQLStrIdColumn() const
Bool_tSQLTestTable(const char* tablename)
const char*SQLValueQuote() const
Long64_tStoreObjectInTables(Long64_t keyid, const void* obj, const TClass* cl)
Int_tStreamKeysForDirectory(TDirectory* dir, Bool_t doupdate, Long64_t specialkeyid = -1, TKeySQL** specialkey = 0)
virtual Int_tSysClose(Int_t)
virtual Int_tSysOpen(const char*, Int_t, UInt_t)
virtual Int_tSysRead(Int_t, void*, Int_t)
virtual Long64_tSysSeek(Int_t, Long64_t, Int_t)
virtual Int_tSysStat(Int_t, Long_t*, Long64_t*, Long_t*, Long_t*)
virtual Int_tSysSync(Int_t)
virtual Int_tSysWrite(Int_t, const void*, Int_t)
voidTDirectory::UnregisterContext(TDirectory::TContext* ctxt)
Bool_tUpdateKeyData(TKeySQL* key)
Int_tTFile::WriteBufferViaCache(const char* buf, Int_t len)
Bool_tWriteKeyData(TKeySQL* key)
Bool_tWriteSpecialObject(Long64_t keyid, TObject* obj, const char* name, const char* title)
voidoperator=(const TSQLFile&)

Data Members

static TFile::EAsyncOpenStatusTFile::kAOSFailure
static TFile::EAsyncOpenStatusTFile::kAOSInProgress
static TFile::EAsyncOpenStatusTFile::kAOSNotAsync
static TFile::EAsyncOpenStatusTFile::kAOSSuccess
static TFile::ERelativeToTFile::kBeg
static TFile::EStatusBitsTFile::kBinaryFile
static TObject::(anonymous)TObject::kBitMask
static TObject::EStatusBitsTObject::kCanDelete
static TObject::EStatusBitsTObject::kCannotPick
static TDirectoryFile::(anonymous)TDirectoryFile::kCloseDirectory
static TFile::ERelativeToTFile::kCur
static TFile::EFileTypeTFile::kDefault
static TFile::EStatusBitsTFile::kDevNull
static TFile::ECacheActionTFile::kDisconnect
static TFile::ECacheActionTFile::kDoNotDisconnect
static TFile::ERelativeToTFile::kEnd
static TFile::EOpenTimeOutTFile::kEternalTimeout
static TFile::EFileTypeTFile::kFile
static TFile::EStatusBitsTFile::kHasReferences
static TObject::EStatusBitsTObject::kHasUUID
static TSQLFile::EIndexesKindskIndexesAll
static TSQLFile::EIndexesKindskIndexesBasic
static TSQLFile::EIndexesKindskIndexesClass
static TSQLFile::EIndexesKindskIndexesNone
static TFile::EOpenTimeOutTFile::kInstantTimeout
static TObject::EStatusBitsTObject::kInvalidObject
static TObject::(anonymous)TObject::kIsOnHeap
static TObject::EStatusBitsTObject::kIsReferenced
static TFile::EFileTypeTFile::kLocal
static TFile::EFileTypeTFile::kMerge
static TObject::EStatusBitsTObject::kMustCleanup
static TFile::EFileTypeTFile::kNet
static TObject::EStatusBitsTObject::kNoContextMenu
static TObject::(anonymous)TObject::kNotDeleted
static TObject::EStatusBitsTObject::kObjInCanvas
static TObject::(anonymous)TObject::kOverwrite
static TFile::EStatusBitsTFile::kRecovered
static TFile::EStatusBitsTFile::kRedirected
static TObject::(anonymous)TObject::kSingleKey
static TFile::(anonymous)TFile::kStartBigFile
static TSQLFile::ETransactionKindskTransactionsAuto
static TSQLFile::ETransactionKindskTransactionsOff
static TSQLFile::ETransactionKindskTransactionsUser
static TFile::EFileTypeTFile::kWeb
static TObject::(anonymous)TObject::kWriteDelete
static TFile::EStatusBitsTFile::kWriteError
static TObject::(anonymous)TObject::kZombie
TArchiveFile*TFile::fArchive!Archive file from which we read this file
Long64_tTFile::fArchiveOffset!Offset at which file starts in archive
Int_tfArrayLimit! limit for array size. when array bigger, its content converted to raw format
TFileOpenHandle*TFile::fAsyncHandle!For proper automatic cleanup
TFile::EAsyncOpenStatusTFile::fAsyncOpenStatus!Status of an asynchronous open request
Long64_tTFile::fBEGINFirst used byte in file
const char**fBasicTypes! pointer on list of basic types specific for currently connected SQL server
Int_tTDirectoryFile::fBufferSizeDefault buffer size to create new TKeys
Long64_tTFile::fBytesReadNumber of bytes read from this file
Long64_tTFile::fBytesReadExtraNumber of extra bytes (overhead) read by the readahead buffer
Long64_tTFile::fBytesWriteNumber of bytes written to this file
TFileCacheRead*TFile::fCacheRead!Pointer to the read cache (if any)
TMap*TFile::fCacheReadMap!Pointer to the read cache (if any)
TFileCacheWrite*TFile::fCacheWrite!Pointer to the write cache (if any)
Bool_tfCanChangeConfig! variable indicates can be basic configuration changed or not
TArrayC*TFile::fClassIndex!Index of TStreamerInfo classes written to this file
Int_tTFile::fCompressCompression level and algorithm
TDirectory::TContext*TDirectory::fContext!Pointer to a list of TContext object pointing to this TDirectory
Int_tTFile::fDFile descriptor
TDatimeTDirectoryFile::fDatimeCDate and time when directory is created
TDatimeTDirectoryFile::fDatimeMDate and time of last modification
Long64_tTFile::fENDLast used byte in file
TFile*TDirectoryFile::fFilepointer to current file in memory
TList*TFile::fFreeFree segments linked list table
Bool_tfIdsTableExists! indicate if IdsTable exists
TList*TFile::fInfoCache!Cached list of the streamer infos in this file
Bool_tTFile::fInitDone!True if the file has been initialized
Bool_tTFile::fIsArchive!True if this is a pure archive file
Bool_tTFile::fIsPcmFile!True if the file is a ROOT pcm file.
Bool_tTFile::fIsRootFile!True is this is a ROOT file, raw file otherwise
TList*TDirectoryFile::fKeysPointer to keys list in memory
TList*TDirectory::fListList of objects in memory
ofstream*fLogFile! log file with SQL statements
Bool_tTDirectoryFile::fModifiedtrue if directory has been modified
Int_tfModifyCounter! indicates how many changes was done with database tables
TObject*TDirectory::fMotherpointer to mother of the directory
Bool_tTFile::fMustFlush!True if the file buffers must be flushed
Int_tTFile::fNProcessIDsNumber of TProcessID written to this file
TStringTNamed::fNameobject identifier
Int_tTFile::fNbytesFreeNumber of bytes for free segments structure
Int_tTFile::fNbytesInfoNumber of bytes for StreamerInfo record
Int_tTDirectoryFile::fNbytesKeysNumber of bytes for the keys
Int_tTDirectoryFile::fNbytesNameNumber of bytes in TNamed at creation time
Bool_tTFile::fNoAnchorInName!True if we don't want to force the anchor to be appended to the file name
Long64_tTFile::fOffset!Seek offset cache
TList*TFile::fOpenPhases!Time info about open phases
TStringTFile::fOptionFile options
const char**fOtherTypes! pointer on list of other SQL types like TEXT or blob
TStringTDirectory::fPathBuffer!Buffer for GetPath() function
TObjArray*TFile::fProcessIDs!Array of pointers to TProcessIDs
Int_tfQuerisCounter! how many query was applied
Int_tTFile::fReadCallsNumber of read calls ( not counting the cache calls )
TStringTFile::fRealNameEffective real file name (not original url)
TSQLServer*fSQL! interface to SQL database
TList*fSQLClassInfos! list of SQL class infos
Int_tfSQLIOversion! version of SQL I/O which is stored in configurations
Long64_tTDirectoryFile::fSeekDirLocation of directory on file
Long64_tTFile::fSeekFreeLocation on disk of free segments structure
Long64_tTFile::fSeekInfoLocation on disk of StreamerInfo record
Long64_tTDirectoryFile::fSeekKeysLocation of Keys record on file
Long64_tTDirectoryFile::fSeekParentLocation of parent directory on file
Int_tfStmtCounter! count numbers of active statements
Double_tTFile::fSum2BufferSum of squares of buffer sizes of objects written so far
Double_tTFile::fSumBufferSum of buffer sizes of objects written so far
TStringfTablesType! type, used in CREATE TABLE statements
TStringTNamed::fTitleobject title
TUUIDTDirectory::fUUIDUnique identifier
Char_tTFile::fUnitsNumber of bytes for file pointers
TUrlTFile::fUrl!URL of file
Int_tfUseIndexes! use indexes for tables: 0 - off, 1 - only for basic tables, 2 + normal class tables, 3 - all tables
Bool_tfUseSuffixes! use suffixes in column names like fValue:Int_t or fObject:pointer
Int_tfUseTransactions! use transaction statements for writing data into the tables
TStringfUserName! user name, used to access objects from database
Int_tTFile::fVersionFile format version
Bool_tTDirectoryFile::fWritabletrue if directory is writable
Int_tTFile::fWrittenNumber of objects written so far
static Bool_tTDirectory::fgAddDirectory!flag to add histograms, graphs,etc to the directory
static TList*TFile::fgAsyncOpenRequestsList of handles for pending open requests
static atomic<Long64_t>TFile::fgBytesReadNumber of bytes read by all TFile objects
static atomic<Long64_t>TFile::fgBytesWriteNumber of bytes written by all TFile objects
static TStringTFile::fgCacheFileDirDirectory where to locally stage files
static Bool_tTFile::fgCacheFileDisconnectedIndicates, we trust in the files in the cache dir without stat on the cached file
static Bool_tTFile::fgCacheFileForceIndicates, to force all READ to CACHEREAD
static atomic<Long64_t>TFile::fgFileCounterCounter for all opened files
static Bool_tTFile::fgOnlyStagedBefore the file is opened, it is checked, that the file is staged, if not, the open fails
static UInt_tTFile::fgOpenTimeoutTimeout for open operations in ms - 0 corresponds to blocking i/o
static atomic<Int_t>TFile::fgReadCallsNumber of bytes read from all TFile objects
static Bool_tTFile::fgReadInfoif true (default) ReadStreamerInfo is called when opening a file
static Int_tTFile::fgReadaheadSizeReadahead buffer size
static TSQLFile::ELockingKindskLockBusy
static TSQLFile::ELockingKindskLockFree

Class Charts

Inheritance Chart:

Function documentation

 default TSQLFile constructor
TSQLFile(const char* dbname, Option_t* option = "read", const char* user = "user", const char* pass = "pass")
 Connects to SQL server with provided arguments.
 If the constructor fails in any way IsZombie() will
 return true. Use IsOpen() to check if the file is (still) open.

 If option = NEW or CREATE   create a ROOT tables in database
                             if the tables already exists connection is
                             not opened.
           = RECREATE        create completely new tables. Any existing tables
                             will be deleted
           = UPDATE          open an existing database for writing.
                             If data base open by other TSQLFile instance for writing,
                             write access will be rejected
           = BREAKLOCK       Special case when lock was not correctly released
                             by TSQLFile instance. This may happen if program crashed when
                             TSQLFile was open with write access mode.
           = READ or OPEN    open an existing data base for reading.

 For more details see comments for TFile::TFile() constructor

 For a moment TSQLFile does not support TTree objects and subdirectories
void StartLogFile(const char* fname)
 start logging of all SQL statements in specified file
void StopLogFile()
 close logging file
Bool_t IsMySQL() const
 checks, if MySQL database
Bool_t IsOracle() const
 checks, if Oracle database
Bool_t IsODBC() const
 checks, if ODBC driver used for database connection
void SetUseSuffixes(Bool_t on = kTRUE)
 enable/disable uasge of suffixes in columns names
 can be changed before first object is saved into file
void SetArrayLimit(Int_t limit = 20)
 Defines maximum number of columns for array representation
 If array size bigger than limit, array data will be converted to raw format
 This is usefull to prevent tables with very big number of columns
 If limit==0, all arrays will be stored in raw format
 If limit<0, all array values will be stored in column form
 Default value is 21
void SetTablesType(const char* table_type)
 Defines tables type, which is used in CREATE TABLE statements
 Now is only used for MySQL database, where following types are supported:
    "BDB", "HEAP", "ISAM", "InnoDB", "MERGE", "MRG_MYISAM", "MYISAM"
 Default for TSQLFile is "InnoDB". For more detailes see MySQL docs.
void SetUseTransactions(Int_t mode = kTransactionsAuto)
 Defines usage of transactions statements for writing objects data to database.
    kTransactionsOff=0   - no transaction operation are allowed
    kTransactionsAuto=1  - automatic mode. Each write operation,
        produced by TSQLFile, will be supplied by START TRANSACTION and COMMIT calls.
        If any error happen, ROLLBACK will returns database to previous state
    kTransactionsUser=2  - transactions are delegated to user. Methods
        StartTransaction(), Commit() and Rollback() should be called by user.
 Default UseTransactions option is kTransactionsAuto
Bool_t StartTransaction()
 Start user transaction.
 This can be usesfull, when big number of objects should be stored in
 data base and commitment required only if all operations were successful.
 In that case in the end of all operations method Commit() should be
 called. If operation on user-level is looks like not successfull,
 method Rollback() will return database data and TSQLFile instance to
 previous state.
 In MySQL not all tables types support transaction mode of operation.
 See SetTablesType() method for details .
Bool_t Commit()
 Commit transaction, started by StartTransaction() call.
 Only after that call data will be written and visible on database side.
Bool_t Rollback()
 Rollback all operations, done after StartTransaction() call.
 Database should return to initial state.
void SetUseIndexes(Int_t use_type = kIndexesBasic)
 Specify usage of indexes for data tables
    kIndexesNone = 0  - no indexes are used
    kIndexesBasic = 1 - indexes used only for keys list and
                        objects list tables (default)
    kIndexesClass = 2 - index also created for every normal class table
    kIndexesAll = 3   - index created for every table, including _streamer_ tables
 Indexes in general should increase speed of access to objects data,
 but they required more operations and more disk space on server side
const char* GetDataBaseName() const
 Return name of data base on the host
 For Oracle always return 0
void Close(Option_t* option = "")
 Close a SQL file
 For more comments see TFile::Close() function
 destructor of TSQLFile object
void operator=(const TSQLFile& )
 make private to exclude copy operator
Bool_t IsOpen() const
 return kTRUE if file is opened and can be accessed
Int_t ReOpen(Option_t* mode)
 Reopen a file with a different access mode, like from READ to
 See TFile::Open() for details
TKey* CreateKey(TDirectory* mother, const TObject* obj, const char* name, Int_t bufsize)
 create SQL key, which will store object in data base
TKey* CreateKey(TDirectory* mother, const void* obj, const TClass* cl, const char* name, Int_t bufsize)
 create SQL key, which will store object in data base
void WriteHeader()
 Write file info like configurations, title, UUID and other
void WriteStreamerInfo()
 Store all TVirtualStreamerInfo, used in file, in sql database
Bool_t WriteSpecialObject(Long64_t keyid, TObject* obj, const char* name, const char* title)
 write special kind of object like streamer infos or file itself
 keys for that objects should exist in tables but not indicated in list of keys,
 therefore users can not get them with TDirectoryFile::Get() method
TObject* ReadSpecialObject(Long64_t keyid, TObject* obj = 0)
 Read data of special kind of objects
TList* GetStreamerInfoList()
 Read back streamer infos from database
 List of streamer infos is always stored with key:id 0,
 which is not shown in normal keys list
void SaveToDatabase()
 save data which is not yet in Database
 Typically this is streamerinfos structures or
Int_t StreamKeysForDirectory(TDirectory* dir, Bool_t doupdate, Long64_t specialkeyid = -1, TKeySQL** specialkey = 0)
 read keys for specified directory (when update == kFALSE)
 or update value for modified keys when update == kTRUE
 Returns number of successfully read keys or -1 if error
void InitSqlDatabase(Bool_t create)
 initialize sql database and correspondent structures
 identical to TFile::Init() function
Bool_t ReadConfigurations()
 read table configurations as special table
void CreateBasicTables()
 Creates initial tables in database
 This is table with configurations and table with keys
 Function called once when first object is stored to the file.
void IncrementModifyCounter()
 Update value of modify counter in config table
 Modify counter used to indicate that something was changed in database.
 It will be used when multiple instances of TSQLFile for the same data base
 will be connected.
TString MakeSelectQuery(TClass* cl)
 Produce SELECT statement which can be used to get all data
 of class cl in one SELECT statement
 This statement also can be used to create VIEW by command like
 Where $CLASSSELECT$ argument should be produced by call
 VIEWs supported by latest MySQL 5 and Oracle
Bool_t ProduceClassSelectQuery(TVirtualStreamerInfo* info, TSQLClassInfo* sqlinfo, TString& columns, TString& tables, Int_t& tablecnt)
 used by MakeClassSelectQuery method to add columns from table of
 class, specified by TVirtualStreamerInfo structure
Bool_t IsTablesExists()
 Checks if main keys table is existing
Bool_t IsWriteAccess()
 Checkis, if lock is free in configuration tables
void SetLocking(Int_t mode)
 Set locking mode for current database
Int_t GetLocking()
 Return current locking mode for that file
Bool_t IsReadAccess()
 dummy, in future should check about read access to database
TSQLResult* SQLQuery(const char* cmd, Int_t flag = 0, Bool_t* res = 0)
 submits query to SQL server
 if flag==0, result is not interesting and will be deleted
 if flag==1, return result of submitted query
 if flag==2, results is may be necessary for long time
             Oracle plugin do not support working with several TSQLResult
             objects, therefore explicit deep copy will be produced
 If ok!=0, it will contains kTRUE is Query was successfull, otherwise kFALSE
Bool_t SQLCanStatement()
 Test if DB support statement and number of open statements is not exceeded
TSQLStatement* SQLStatement(const char* cmd, Int_t bufsize = 1000)
 Produces SQL statement for currently conected DB server
void SQLDeleteStatement(TSQLStatement* stmt)
 delete statement and decrease counter
Bool_t SQLApplyCommands(TObjArray* cmds)
 supplies set of commands to server
 Commands is stored as array of TObjString
Bool_t SQLTestTable(const char* tablename)
 Test, if table of specified name exists
Long64_t SQLMaximumValue(const char* tablename, const char* columnname)
 Returns maximum value, found in specified columnname of table tablename
 Column type should be numeric
void SQLDeleteAllTables()
 Delete all tables in database
Bool_t SQLStartTransaction()
 Start SQL transaction.
Bool_t SQLCommit()
 Commit SQL transaction
Bool_t SQLRollback()
 Rollback all SQL operations, done after start transaction
Int_t SQLMaxIdentifierLength()
 returns maximum allowed length of identifiers
void DeleteKeyFromDB(Long64_t keyid)
 remove key with specified id from keys table
 also removes all objects data, related to this table
TKeySQL* FindSQLKey(TDirectory* dir, Long64_t keyid)
 Search for TKeySQL object with specified keyid
Bool_t WriteKeyData(TKeySQL* key)
 add entry into keys table
Bool_t UpdateKeyData(TKeySQL* key)
 updates (overwrites) key data in KeysTable
Long64_t DefineNextKeyId()
 Returns next possible key identifier
TSQLClassInfo* FindSQLClassInfo(const char* clname, Int_t version)
 return (if exists) TSQLClassInfo for specified class name and version
TSQLClassInfo* FindSQLClassInfo(const TClass* cl)
 return (if exists) TSQLClassInfo for specified class
TSQLClassInfo* RequestSQLClassInfo(const char* clname, Int_t version)
 search in database tables for specified class and return TSQLClassInfo object
TString DefineTableName(const char* clname, Int_t version, Bool_t rawtable)
 proposes table name for class
Bool_t HasTable(const char* name)
 test if table name exists
TSQLClassInfo* RequestSQLClassInfo(const TClass* cl)
 search in database tables for specified class and return TSQLClassInfo object
void ReadSQLClassInfos()
 Read all class infos from IdsTable
void AddIdEntry(Long64_t tableid, Int_t subid, Int_t type, const char* name, const char* sqlname, const char* info)
 Add entry into IdsTable, where all tables names and columns names are listed
Bool_t CreateClassTable(TSQLClassInfo* sqlinfo, TObjArray* colinfos)
 Create normal class table if required
Bool_t CreateRawTable(TSQLClassInfo* sqlinfo)
create the raw table
Bool_t VerifyLongStringTable()
 Checks that table for big strings is exists
 If not, will be created
TString CodeLongString(Long64_t objid, Int_t strid)
 produces id which will be placed in column instead of string itself
Int_t IsLongStringCode(Long64_t objid, const char* value)
 checks if this is long string code
 returns 0, if not or string id
Bool_t GetLongString(Long64_t objid, Int_t strid, TString& value)
 returns value of string, extracted from special table,
 where long strings are stored
Long64_t VerifyObjectTable()
 Checks that objects table is exists
 If not, table will be created
 Returns maximum value for existing objects id
Bool_t SQLObjectInfo(Long64_t objid, TString& clname, Version_t& version)
 Read from objects table data for specified objectid
TObjArray* SQLObjectsInfo(Long64_t keyid)
 Produce array of TSQLObjectInfo objects for all objects, belong to that key
 Array should be deleted by calling function afterwards
TSQLResult* GetNormalClassData(Long64_t objid, TSQLClassInfo* sqlinfo)
 Method return request result for specified objid from normal classtable
TSQLResult* GetNormalClassDataAll(Long64_t minobjid, Long64_t maxobjid, TSQLClassInfo* sqlinfo)
 return data for several objects from the range from normal class table
TSQLResult* GetBlobClassData(Long64_t objid, TSQLClassInfo* sqlinfo)
  Method return request results for specified objid from _streamer_ classtable
TSQLStatement* GetBlobClassDataStmt(Long64_t objid, TSQLClassInfo* sqlinfo)
  Method return request results for specified objid from _streamer_ classtable
  Data returned in form of statement, where direct access to values are possible
Long64_t StoreObjectInTables(Long64_t keyid, const void* obj, const TClass* cl)
 Store object in database. Return stored object id or -1 if error
const char* SQLCompatibleType(Int_t typ) const
 returns sql type name which is most closer to ROOT basic type
 typ should be from TVirtualStreamerInfo:: constansts like TVirtualStreamerInfo::kInt
const char* SQLIntType() const
 return SQL integer type
Long64_t DirCreateEntry(TDirectory* )
 Create entry for directory in database
Int_t DirReadKeys(TDirectory* )
 Read directory list of keys from database
void DirWriteKeys(TDirectory* )
 Write directory keys list to database
void DirWriteHeader(TDirectory* )
 Update dir header in the file
void Streamer(TBuffer& )
 streamer for TSQLFile class
 stores only data for TDirectory
Int_t SysOpen(const char* , Int_t , UInt_t )
 Interface to basic system I/O routines, suppressed
{ return 0; }
Int_t SysClose(Int_t )
{ return 0; }
Int_t SysRead(Int_t , void* , Int_t )
{ return 0; }
Int_t SysWrite(Int_t , const void* , Int_t )
{ return 0; }
Long64_t SysSeek(Int_t , Long64_t , Int_t )
{ return 0; }
Int_t SysStat(Int_t , Long_t* , Long64_t* , Long_t* , Long_t* )
{ return 0; }
Int_t SysSync(Int_t )
{ return 0; }
const char* SQLSmallTextType() const
{ return fOtherTypes[0]; }
Int_t SQLSmallTextTypeLimit() const
{ return atoi(fOtherTypes[1]); }
const char* SQLBigTextType() const
{ return fOtherTypes[2]; }
const char* SQLDatetimeType() const
{ return fOtherTypes[3]; }
const char* SQLIdentifierQuote() const
{ return fOtherTypes[4]; }
const char* SQLDirIdColumn() const
{ return fOtherTypes[5]; }
const char* SQLKeyIdColumn() const
{ return fOtherTypes[6]; }
const char* SQLObjectIdColumn() const
{ return fOtherTypes[7]; }
const char* SQLRawIdColumn() const
{ return fOtherTypes[8]; }
const char* SQLStrIdColumn() const
{ return fOtherTypes[9]; }
const char* SQLNameSeparator() const
{ return fOtherTypes[10]; }
const char* SQLValueQuote() const
{ return fOtherTypes[11]; }
const char* SQLDefaultTableType() const
{ return fOtherTypes[12]; }
Bool_t GetUseSuffixes() const
 configuration of SQL
{ return fUseSuffixes; }
Int_t GetArrayLimit() const
{ return fArrayLimit; }
void SkipArrayLimit()
{ SetArrayLimit(-1); }
const char* GetTablesType() const
{ return fTablesType.Data(); }
Int_t GetUseTransactions() const
{ return fUseTransactions; }
Int_t GetUseIndexes() const
{ return fUseIndexes; }
Int_t GetQuerisCounter() const
{ return fQuerisCounter; }
void DrawMap(const char* = "*", Option_t* = "")
void FillBuffer(char*& )
void Flush()
Long64_t GetEND() const
{ return 0; }
Int_t GetErrno() const
{ return 0; }
void ResetErrno() const
Int_t GetNfree() const
{ return 0; }
Int_t GetNbytesInfo() const
{return 0; }
Int_t GetNbytesFree() const
{return 0; }
Long64_t GetSeekFree() const
{return 0; }
Long64_t GetSeekInfo() const
{return 0; }
Long64_t GetSize() const
{ return 0; }
void MakeFree(Long64_t , Long64_t )
void MakeProject(const char* , const char* = "*", Option_t* = "new")
void Map()
void Paint(Option_t* = "")
void Print(Option_t* = "") const
Bool_t ReadBuffer(char* , Int_t )
{ return kFALSE; }
Bool_t ReadBuffer(char* , Long64_t , Int_t )
{ return kFALSE; }
void ReadFree()
Int_t Recover()
{ return 0; }
void Seek(Long64_t , TFile::ERelativeTo = kBeg)
void SetEND(Long64_t )
Int_t Sizeof() const
{ return 0; }
Bool_t WriteBuffer(const char* , Int_t )
{ return kFALSE; }
Int_t Write(const char* = 0, Int_t = 0, Int_t = 0)
{ return 0; }
Int_t Write(const char* = 0, Int_t = 0, Int_t = 0) const
{ return 0; }
void WriteFree()