Derby
  1. Derby
  2. DERBY-5612

Puzzling documentation about the URL to a database on the classpath

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 10.9.1.0
    • Fix Version/s: 10.9.1.0
    • Component/s: Documentation
    • Labels:
      None
    • Urgency:
      Normal

      Description

      The "Accessing databases from the classpath" section of the Derby Developer's Guide says that you can access a database on the classpath by putting a forward slash in front of the database name (and then adding other path legs as needed). I don't find that it works this way. I ran the following experiment:

      1) I put a database called nast in the testRun/extin subdirectory of the current directory.

      2) Then I put testRun/extin on the classpath.

      3) Then I tried connecting to the database with various URLs.

      The following URLs could not find the database:

      connect 'jdbc:derby:/nast;user=KIWI;password=KIWI_password';
      connect 'jdbc:derby:nast;user=KIWI;password=KIWI_password';
      connect 'jdbc:derby:classpath:/nast;user=KIWI;password=KIWI_password';

      But the following URL found the database:

      connect 'jdbc:derby:classpath:nast;user=KIWI;password=KIWI_password';

      This is not what I expected from the documentation in the Developer's Guide.

      1. DERBY-5612.diff
        7 kB
        Kim Haase
      2. DERBY-5612.stat
        0.3 kB
        Kim Haase
      3. DERBY-5612.zip
        16 kB
        Kim Haase
      4. DERBY-5612-2.diff
        12 kB
        Kim Haase
      5. DERBY-5612-2.stat
        0.3 kB
        Kim Haase
      6. DERBY-5612-2.zip
        12 kB
        Kim Haase

        Issue Links

          Activity

          No work has yet been logged on this issue.

            People

            • Assignee:
              Kim Haase
              Reporter:
              Rick Hillegas
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Development