Read a SQLite db file and convert it to TTree


Please read tips for efficient and successful posting and posting code

ROOT Version: v6-30-02
Platform: Ubuntu-20.4 on Windows
Compiler: Not Provided


Dear Expert,

I am trying to convert a SQLite file like ArchiveLog_2025-11-28.db to a root tree file. But I can not find a way to open this file by ROOT. When I try to run the tutorials about SQLite in root/tutorials/sql like SQLitePlatformDistribution.C, I got some error like:
```

Processing SQLitePlatformDistribution.C...
In file included from input_line_8:1:
/home/wztbxl/root/root-630install/tutorials/sql/SQLitePlatformDistribution.C:20:10: fatal error: 'TSQLiteServer.h' file not found
#include <TSQLiteServer.h> 

Do I miss something or Do we have some new tutorials about that?

Thanks

Zhen

Hi @wztbxl,

thank you for your question. Maybe @bellenot could help here?

Cheers,

Marta

Did you download root_v6.30.02.Linux-ubuntu20.04-x86_64-gcc9.4.tar.gz tar file? I see TSQLiteServer.h in its include directory. Can you check?

Hello,
I download the source code root_v6.30.02.source.tar.gz and install root. I didnot find the TSQLiteServer.h in the include directory

image

Do I need to use this root_v6.30.02.Linux-ubuntu20.04-x86_64-gcc9.4.tar.gz file?
Best,

Zhen

So you built ROOT yourself? In that case you probably didn’t specify -Dsqlite=ON at configure time, or you don’t have SQLite installed (sqlite3 libsqlite3-dev). You can check with root-config --features.
Can you try with the pre-built binary?

Hello,

I tried root-config --features

It shows

cxx17 asimage builtin_afterimage builtin_clang builtin_cling builtin_davix builtin_llvm builtin_nlohmannjson builtin_openui5 builtin_vdt builtin_xrootd clad dataframe davix fitsio gdml http imt mlp mysql opengl proof pyroot roofit webgui root7 rpath runtime_cxxmodules shared ssl tmva tmva-pymva spectrum vdt x11 xml xrootd

I think you are right, I did not add the -Dsqlite=ON at configure time. I will try the pre-built binary

Thanks,

Zhen