Questions tagged [sqlitejdbc]

SQLite JDBC is the JDBC interface of SQLite database. It supports both single thread and thread-safe operation modes. Questions tagged by this tag should also be tagged Sqlite.

SQLite JDBC is the JDBC interface of SQLite database.

There are multiple JDBC drivers for this database:

  • Xerial that uses the packaged native libraries for different platforms. The authors claim that using native code makes the driver faster.
  • the Zentus that is pure Java-only implementation. The initial project page is here but seems not available at the time of writing. The backed up content can be found here in GitHub.

Both can be easily added to project by just adding them to classpath.

The thread safety of the SQLite JDBC connection depends on the SQLite operation mode and can be single thread, multiple thread but only one per connection and serialized (no restrictions). The operation mode should be selected at compile time. With certain limitations, it can be further changed at start time, some changes are also possible at run time.

62 questions
15
votes
2 answers

Derby/JavaDB vs SQLiteJDBC

I found a lot of comparisions here, but not this one; So, what is best in each one?
The Student
  • 27,520
  • 68
  • 161
  • 264
9
votes
1 answer

Do I need to install SQLite so that SQLiteJDBC works?

I guess I'm just not "getting it". If I don't have SQLite already installed on my computer, and I want to write a Java app that uses an embedded database, and I download/import the SQLiteJDBC JAR into my project, is that all I need? Or, do I need to…
Massie
  • 165
  • 1
  • 2
  • 5
9
votes
2 answers

How do I list all the available views of a particular table in SQLite?

I want to access all the particular views of any particular table in Sqlite . I know I can get the list of all the available tables in the database using sqlite_master SELECT name from sqlite_master WHERE type='table'; And the list of all the…
rush00121
  • 185
  • 1
  • 5
  • 13
7
votes
2 answers

Are the pure Java SQLiteJDBC drivers really pure?

I am making the decision for an embededded database in an upcoming Java servlet application. I am down to two final contenders: SQLite with SQLiteJDBC "pure Java" drivers vs Java DB (aka Derby). Here is my killer criteria: The application must…
John Fitzpatrick
  • 4,207
  • 7
  • 48
  • 71
4
votes
3 answers

SQLException : no such column

I'm a new member. I have been struggling with sqlitejdbc, I thought. I made a query to sqlite database from a java program.I got above exception. My query is select * from ( person as p inner join company as c on p.p_id=c.p_id ) …
waiyan
  • 145
  • 1
  • 4
  • 8
4
votes
2 answers

Does SQLiteJDBC can work without SQLite installed, and can it initialize the database tables?

I've tried finding this out on my own but to no avail. I'm writing a Java app that will use an embedded SQLite database through Zentu's SQLiteJDBC. I am making the following assumptions and need confirmation on all of them, and where I'm wrong,…
IAmYourFaja
  • 55,468
  • 181
  • 466
  • 756
4
votes
2 answers

How can I convert an int (UNIX timestamp) to datetime in SQLite?

I have to create a table in SQL(I am using IntelliJ and Java), and the table must respect the following restrictions. The table will contain the following columns: title - needs to be able to store letters, digits, and special…
Esmer Omer
  • 65
  • 5
4
votes
1 answer

How to access my sqlite db file placed in /tmp folder from my servlet class?

I am writing a JSP-Servlet application where I need to write to and read from a sqlite db. The db is temporary one to which one of my cron jobs write data to and my servlet-jsp app reads thise data and occasionally updates it Now I am trying to…
Priyadarshi Kunal
  • 568
  • 3
  • 7
  • 21
4
votes
2 answers

SQLiteJDBC and PreparedStatement to use pragma table_info

I'm utilizing Java and SQLiteJDBC to work with SQLite. I need to access name of columns for a given table and I've found that I could accomplish this with the following command: pragma table_info(myTable) However, when attempting to do the…
Frank V
  • 25,141
  • 34
  • 106
  • 144
4
votes
1 answer

host a SQLite .db file on dropbox.com

First of all, can anybody tell me if Dropbox.com has write access. if so then how would you access an SQLite .db file hosted there within your Java applet specs: I'm using Eclipse Helios Using David Crawshaw's SQLite jdbc driver (v. 056) not sure…
Dylan
  • 47
  • 2
  • 8
3
votes
2 answers

SQLiteJDBC giving org.sqlite.MetaData.getImportedKeys not yet implemented error with Hibernate

SQLiteJDBC was giving me the following exception when used with hibernate's "hbm2ddl.auto = update" setting: org.sqlite.MetaData.getImportedKeys not yet implemented Any solutions? I found one below, and am posting it here for my future reference,…
Chris
  • 39,719
  • 45
  • 189
  • 235
3
votes
1 answer

Inspect or Visualize in memory database created using sqlite jdbc during debug

I am creating a temporary sqlite jdbc database structure in memory. Somehitng like this, Connection connection = DriverManager.getConnection("jdbc:sqlite::memory:"); However, it would be really nice to be able to see/visualize this database while…
Indigo
  • 2,887
  • 11
  • 52
  • 83
2
votes
2 answers

SQLDroid JDBC driver for Android

I need to use a database on an Android application, since when in use the user won't have internet access. For that, I want to do a connection to the database via JDBC with SQL Lite. After some research I found out that it is not supported by the…
Paulo Barros
  • 2,740
  • 8
  • 28
  • 36
2
votes
2 answers

JDBC PreparedStatement.setString throws Out Of Bounds exception

I have a simple PreparedStatement string like this: INSERT INTO albums (name, date) VALUES (?, ?) I have created the table with this: CREATE TABLE "albums" ( "id" INTEGER NOT NULL PRIMARY KEY AUTOINCREMENT, "name" TEXT NOT NULL, …
2
votes
3 answers

SQLite implementations in Java and C#

I've been using SQLite in my Java and C# applications, making use of the System.Data.SQLite library for C# and the Zentus SQLiteJDBC Driver for Java. I've noticed that the Java implementation allows the use of the readily available SQL libraries…
Jamie Keeling
  • 9,806
  • 17
  • 65
  • 102
1
2 3 4 5