db-derby-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Deepa Remesh (JIRA)" <derby-...@db.apache.org>
Subject [jira] Commented: (DERBY-597) Enhance ij connect statement to work in J2ME/CDC/FP
Date Mon, 24 Oct 2005 23:34:56 GMT
    [ http://issues.apache.org/jira/browse/DERBY-597?page=comments#action_12355675 ] 

Deepa Remesh commented on DERBY-597:
------------------------------------

setCreateDatabase is called using the value in ij.dataSource.createDatabase property. But
in connect statement, if a database needs to be created it will be specified as an attribute
(create=true). Hence I am not calling setCreateDatabase in this case. So if there is a ij>
connect 'somenewdb;create=true' and it is not a first connection, database will get created
because the URL has create=true in it. 

I am trying to use one method and a parameter to differentiate what values will be used to
set up the data source. I tried to put more comments in this version of patch explaining what
I am trying to do. Looks like I am not very successful at it which makes this approach not
very intuitive.

Other option that I can think of is to use 2 methods:
1. setupDataSoureFromProperties, which will use properties in ij.dataSource.* and can be called
from startJBMS.
2. setupDataSourceFromUrl, which will use values in the URL and can be called from connectStatement.

If this sounds better, I can rework the patch. 

> Enhance ij connect statement to work in J2ME/CDC/FP
> ---------------------------------------------------
>
>          Key: DERBY-597
>          URL: http://issues.apache.org/jira/browse/DERBY-597
>      Project: Derby
>         Type: Improvement
>   Components: Tools
>     Versions: 10.2.0.0, 10.1.1.1
>  Environment: J2ME/CDC/FP
>     Reporter: Deepa Remesh
>     Assignee: Deepa Remesh
>     Priority: Minor
>  Attachments: derby-597-v2.diff, derby-597-v2.status, derby-597.diff, derby-597.status
>
> The connect statement in ij currently uses DriverManager class to get a connection and
so does not work in J2ME environment. Currently in tests, the startJBMS method can optionally
use DataSource to get a connection. This approach can be used in 'connect' statement too.
This change will allow more tests to be run in J2ME.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


Mime
View raw message