alexey
alexey

Reputation: 35

Where from can I get derby core plugin for eclipse?

Good day!

Where from can I get a new derby core plugin for eclipse?

I found the link

http://archive.apache.org/dist/db/derby/db-derby-10.3.1.4/?C=M;O=A

but there are releases are dated by 2007 year.

Maybe there are another ways(tools) to work with derby db from eclipse?

Upvotes: 1

Views: 2262

Answers (1)

chris
chris

Reputation: 1785

You'll find current downloads for Apache Derby Database here. Version 10.11.1.1 is from August 26, 2014. So i assume it is maintained here.
There is also documentation ('modern tools') contained in the download. I use it without any plug-in for some IDE.
Just a few first steps (windows batch):

create database (all in the same line):

set jvm=path_to_java.exe "%jvm%" -jar "%~dp0db-derby-10.11.1.1-bin\lib\derbyrun.jar" ij "%~dp01_db_create.sql">"log.txt"

1_db_create.sql:

CONNECT 'jdbc:derby:database;create=true';
CREATE TABLE MYTABLE
(
ARTIKEL_NR varchar(35) DEFAULT ' ' NOT NULL
, SPRACHE varchar(3) DEFAULT ' ' NOT NULL
, PRIMARY KEY
(
ARTIKEL_NR
, SPRACHE
));

start server that listens to port 1527 (all in the same line):

set port=1527
set jvm=path_to_java.exe
set cp=path_to_db-derby-10.11.1.1-bin\lib*
"%jvm%" -cp "%cp%" org.apache.derby.drda.NetworkServerControl start -p %port%

connect server to fire sql commands:

set dbname=database
set port=1527
set user=app
set pass=app
set jvm=path_to_java.exe
set cp=path_to_db-derby-10.11.1.1-bin\lib*
set options=-Dij.connection.data=jdbc:derby://localhost:%port%/%dbname%
"%jvm%" -cp "%cp%" %options% org.apache.derby.tools.ij

This connects to the db and you can fire some sql's like select * from mytable

Upvotes: 2

Related Questions