Questions tagged [derby]

Use this tag for questions about Apache Derby, an Apache DB subproject. Derby is an open source relational database implemented entirely in Java and available under the Apache License, Version 2.0.

Apache Derby, an Apache DB subproject, is an open source relational database implemented entirely in Java and available under the Apache License, Version 2.0.

Some key advantages include:

  • a small footprint
  • Java, JDBC, and SQL standards
  • embedded Java-based solutions in addition to traditional client/server support
  • and easy of installation and deployment.

From Java 6 onward a version of Derby is included in the JDK.

Useful Links

2643 questions
20
votes
9 answers

String to java.sql.Date

I realize this has been asked a lot. I did actually look. I've spent hours looking around and trying to figure this out. I'm supposed to be making a program that stores what amounts to a list of appointments in a database, with a description, date,…
Tajha
  • 399
  • 1
  • 5
  • 15
19
votes
5 answers

How to alter a column datatype for derby database?

I am trying to alter a datatype for a derby db column. The current price column is set as DECIMAL(5,0). I would like to alter it to DECIMAL(7,2). I did this : alter table item alter column price set data type DECIMAL(7,2); But it did not work, and…
jl.
  • 2,209
  • 12
  • 49
  • 61
18
votes
8 answers

Embedded (pure Java) database for Clojure

I'm in need for an embedded database for a Clojure application. Maybe it's the same criteria as for any other Java application but I rather get some other people's opinion anyway. I'm not picking SQLite because that's not pure Java so distribution…
Pablo Fernandez
  • 279,434
  • 135
  • 377
  • 622
18
votes
2 answers

Derby or MySQL or...?

For what type of requirements would you choose Apache Derby (or Java DB) over MySQL (or vice versa)? I looked around and people just compare the two but no one talks about when to consider each one. I am developing a web-based application using…
PhD
  • 11,202
  • 14
  • 64
  • 112
17
votes
3 answers

Is there a tool other than ij to look into a local derby database (folder)?

I'm using Derby ij to look into my local Apache Derby database. It's just a folder and I connect to it like this: connect 'jdbc:derby:C:\Users\Torben\MyDatabase' USER 'me' PASSWORD 'secret'; It works, but I don't really like to look into the…
Torben
  • 173
  • 1
  • 1
  • 4
17
votes
6 answers

Spark-Shell Startup Errors

I am seeing errors when starting spark-shell, using spark-1.6.0-bin-hadoop2.6. This is new behavior that just arose. The upshot of the failures displayed in the log messages below, is that sqlContext is not available (but sc is). Is there some kind…
slachterman
  • 1,515
  • 4
  • 17
  • 23
16
votes
3 answers

Does HQL have an equivalent for Restrictions.ilike (for case-insensitive matching)?

I wrote a project for Hibernate+MySQL. Now I'm porting it to Derby (for a number of reasons). Now I discovered that Derby is case sensitive when using LIKE in queries. This could be solved using Restrictions.ilike(...) in Criteria queries... but…
gotch4
  • 13,093
  • 29
  • 107
  • 170
16
votes
3 answers

How to shutdown Derby in-memory database Properly

I'm using derby as an embedded database. Furthermore, I'm using it's in-memory database option for my unit tests. What I can't figure out is how to properly shut down (A quick look at the code) the Derby database. I beleive I have it working for a…
Frank V
  • 25,141
  • 34
  • 106
  • 144
16
votes
1 answer

Derby: CONCAT equivalent

Good day! What is the equivalent function of Derby/Java DB to the CONCAT function of MySQL? I tried using CONCAT to Derby but it commits an error.
Ace Eusebio
  • 403
  • 1
  • 7
  • 17
15
votes
1 answer

using hibernate with embedded derby

i want to use hibernate with embedded derby in a standalone application, and i have some questions: What jars do i need ? What are the necessary hibernate configuration ? Are there any other necessary configuration ? Does it have any…
Mahmoud Saleh
  • 33,303
  • 119
  • 337
  • 498
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
15
votes
6 answers

Which embedded database has maximum SQL compliance, and concurrency support?

My application at present uses Microsoft Access, but now may be hosted on Linux boxes. Additionally while being accessed from multiple computers, one of these may update the records (when its being read by other users). I also require that the…
vikramsjn
  • 1,013
  • 1
  • 10
  • 21
14
votes
11 answers

Delete all tables in Derby DB

How do i delete all the tables in the schema on Apache Derby DB using JDBC?
Shimi Bandiel
  • 5,773
  • 3
  • 40
  • 49
14
votes
4 answers

Why are BOOLEAN type columns problematic in relational database design?

I've been working mostly with Oracle for the past few years, and am quite used to seeing single character varchar columns used as boolean values. I can also see (per stack overflow answers), that suggested type for MySQL is TINYINT. Now I've taken…
pafau k.
  • 1,667
  • 12
  • 20
13
votes
7 answers

Apache Derby: how can I do "insert if not exists"?

I'm giving Apache Derby, aka JavaDB a spin. I can't seem to get around duplicate key issues when inserting records that may already exist. Is there a Derby equivalent to "insert if not exists", or "merge" ? Similarly, is there a way to do…
Limbic System
  • 6,820
  • 7
  • 29
  • 37