You are viewing a plain text version of this content. The canonical link for it is here.
Posted to derby-dev@db.apache.org by "Shazin Sadakath (JIRA)" <ji...@apache.org> on 2009/09/20 12:49:16 UTC

[jira] Created: (DERBY-4383) Cannot connect to Network Server to create a database from a Query Analyzer

Cannot connect to Network Server to create a database from a Query Analyzer
---------------------------------------------------------------------------

                 Key: DERBY-4383
                 URL: https://issues.apache.org/jira/browse/DERBY-4383
             Project: Derby
          Issue Type: Bug
          Components: Network Server
         Environment: Windows 7, Aqua Data Studio 7.0.36, Java 1.6.0_13
            Reporter: Shazin Sadakath
            Priority: Minor


After starting the Network Server trying to connect results in an exception.

Connection failed: The URL 'jdbc:derby://<IP>:<PORT>/' is not properly formed.

PORT is 1400. 

This is when there is no database created. But if I create a database using ij and then try to connect using the query analyzer
then it works fine. But I think we should be able to connect to the Network Server via any query analyzer even without a database already created (thus we can use the query analyzer to create databases, tables etc). 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (DERBY-4383) Cannot connect to Network Server to create a database from a Query Analyzer

Posted by "Shazin Sadakath (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/DERBY-4383?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12757863#action_12757863 ] 

Shazin Sadakath commented on DERBY-4383:
----------------------------------------

I was aware of the fact that, jdbc:derby://IP:PORT/DBNAME;create=true should be used to create a database in derby. In fact I used the command 

connect 'jdbc:derby://IP:PORT/DBNAME;create=true' 

To actually create the database when it didn't allow me to create using Aqua Data Studio query analyzer which I use in my developments. Aqua Data Studio is a JDBC based query analyzer which allows to connect multiple databases (Oracle, Sybase, MySQL etc). Sadly when registering a server it doesn't allow you to specify a direct URL such as jdbc:derby://IP:PORT/DBNAME;create=true
in turn it prompts for Login Name, Password, IP, Port and Database and it creates the URL in the back end depending on which database we want to connect. Which is why I couldn't use the workaround. 

But I tried a cheat by specifying DBNAME;create=true in Database field when registering a server, then it worked. 



> Cannot connect to Network Server to create a database from a Query Analyzer
> ---------------------------------------------------------------------------
>
>                 Key: DERBY-4383
>                 URL: https://issues.apache.org/jira/browse/DERBY-4383
>             Project: Derby
>          Issue Type: Bug
>          Components: Network Server
>         Environment: Windows 7, Aqua Data Studio 7.0.36, Java 1.6.0_13
>            Reporter: Shazin Sadakath
>            Priority: Minor
>
> After starting the Network Server trying to connect results in an exception.
> Connection failed: The URL 'jdbc:derby://192.168.0.206:1400/' is not properly formed.
> This is when there is no database created. But if I create a database using ij and then try to connect using the query analyzer
> then it works fine. But I think we should be able to connect to the Network Server via any query analyzer even without a database already created (thus we can use the query analyzer to create databases, tables etc). 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Issue Comment Edited: (DERBY-4383) Cannot connect to Network Server to create a database from a Query Analyzer

Posted by "Shazin Sadakath (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/DERBY-4383?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12757863#action_12757863 ] 

Shazin Sadakath edited comment on DERBY-4383 at 9/21/09 3:23 AM:
-----------------------------------------------------------------

I was aware of the fact that, jdbc:derby://IP:PORT/DBNAME;create=true should be used to create a database in derby. In fact I used the command 

connect 'jdbc:derby://IP:PORT/DBNAME;create=true' 

To actually create the database in ij when it didn't allow me to create using Aqua Data Studio query analyzer which I use in my developments. Aqua Data Studio is a JDBC based query analyzer which allows to connect multiple databases (Oracle, Sybase, MySQL etc). Sadly when registering a server it doesn't allow you to specify a direct URL such as jdbc:derby://IP:PORT/DBNAME;create=true
in turn it prompts for Login Name, Password, IP, Port and Database and it creates the URL in the back end depending on which database we want to connect. Which is why I couldn't use the workaround. 

But I tried a cheat by specifying DBNAME;create=true in Database field when registering a server, then it worked. 



      was (Author: shazin):
    I was aware of the fact that, jdbc:derby://IP:PORT/DBNAME;create=true should be used to create a database in derby. In fact I used the command 

connect 'jdbc:derby://IP:PORT/DBNAME;create=true' 

To actually create the database when it didn't allow me to create using Aqua Data Studio query analyzer which I use in my developments. Aqua Data Studio is a JDBC based query analyzer which allows to connect multiple databases (Oracle, Sybase, MySQL etc). Sadly when registering a server it doesn't allow you to specify a direct URL such as jdbc:derby://IP:PORT/DBNAME;create=true
in turn it prompts for Login Name, Password, IP, Port and Database and it creates the URL in the back end depending on which database we want to connect. Which is why I couldn't use the workaround. 

But I tried a cheat by specifying DBNAME;create=true in Database field when registering a server, then it worked. 


  
> Cannot connect to Network Server to create a database from a Query Analyzer
> ---------------------------------------------------------------------------
>
>                 Key: DERBY-4383
>                 URL: https://issues.apache.org/jira/browse/DERBY-4383
>             Project: Derby
>          Issue Type: Bug
>          Components: Network Server
>         Environment: Windows 7, Aqua Data Studio 7.0.36, Java 1.6.0_13
>            Reporter: Shazin Sadakath
>            Priority: Minor
>
> After starting the Network Server trying to connect results in an exception.
> Connection failed: The URL 'jdbc:derby://192.168.0.206:1400/' is not properly formed.
> This is when there is no database created. But if I create a database using ij and then try to connect using the query analyzer
> then it works fine. But I think we should be able to connect to the Network Server via any query analyzer even without a database already created (thus we can use the query analyzer to create databases, tables etc). 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (DERBY-4383) Cannot connect to Network Server to create a database from a Query Analyzer

Posted by "Knut Anders Hatlen (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/DERBY-4383?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12757831#action_12757831 ] 

Knut Anders Hatlen commented on DERBY-4383:
-------------------------------------------

If I understand this report correctly, you want to be able to use java.sql.DriverManager.getConnection() to connect to a network server with no database, and use that connection to create a new database. Could you add some more details about how such a connection is supposed to work? Derby doesn't currently have any other way of creating a database than connecting to an URL with a database name and the connection attribute create=true, so even if you could obtain a Connection object not associated with a particular database, it wouldn't help you create a new database.

Could you work around this problem by specifying a URL with a database name and create=true in the query analyzer? For example: jdbc:derby://192.168.0.206:1400/mydb;create=true

> Cannot connect to Network Server to create a database from a Query Analyzer
> ---------------------------------------------------------------------------
>
>                 Key: DERBY-4383
>                 URL: https://issues.apache.org/jira/browse/DERBY-4383
>             Project: Derby
>          Issue Type: Bug
>          Components: Network Server
>         Environment: Windows 7, Aqua Data Studio 7.0.36, Java 1.6.0_13
>            Reporter: Shazin Sadakath
>            Priority: Minor
>
> After starting the Network Server trying to connect results in an exception.
> Connection failed: The URL 'jdbc:derby://192.168.0.206:1400/' is not properly formed.
> This is when there is no database created. But if I create a database using ij and then try to connect using the query analyzer
> then it works fine. But I think we should be able to connect to the Network Server via any query analyzer even without a database already created (thus we can use the query analyzer to create databases, tables etc). 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (DERBY-4383) Cannot connect to Network Server to create a database from a Query Analyzer

Posted by "Shazin Sadakath (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/DERBY-4383?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Shazin Sadakath updated DERBY-4383:
-----------------------------------

    Description: 
After starting the Network Server trying to connect results in an exception.

Connection failed: The URL 'jdbc:derby://192.168.0.206:1400/' is not properly formed.

This is when there is no database created. But if I create a database using ij and then try to connect using the query analyzer
then it works fine. But I think we should be able to connect to the Network Server via any query analyzer even without a database already created (thus we can use the query analyzer to create databases, tables etc). 

  was:
After starting the Network Server trying to connect results in an exception.

Connection failed: The URL 'jdbc:derby://<IP>:<PORT>/' is not properly formed.

PORT is 1400. 

This is when there is no database created. But if I create a database using ij and then try to connect using the query analyzer
then it works fine. But I think we should be able to connect to the Network Server via any query analyzer even without a database already created (thus we can use the query analyzer to create databases, tables etc). 


> Cannot connect to Network Server to create a database from a Query Analyzer
> ---------------------------------------------------------------------------
>
>                 Key: DERBY-4383
>                 URL: https://issues.apache.org/jira/browse/DERBY-4383
>             Project: Derby
>          Issue Type: Bug
>          Components: Network Server
>         Environment: Windows 7, Aqua Data Studio 7.0.36, Java 1.6.0_13
>            Reporter: Shazin Sadakath
>            Priority: Minor
>
> After starting the Network Server trying to connect results in an exception.
> Connection failed: The URL 'jdbc:derby://192.168.0.206:1400/' is not properly formed.
> This is when there is no database created. But if I create a database using ij and then try to connect using the query analyzer
> then it works fine. But I think we should be able to connect to the Network Server via any query analyzer even without a database already created (thus we can use the query analyzer to create databases, tables etc). 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.