GeoTools
  1. GeoTools
  2. GEOT-2541

Oracle 11g Spatial DB Connection

    Details

    • Type: Wish Wish
    • Status: Closed Closed
    • Priority: Major Major
    • Resolution: Cannot Reproduce
    • Affects Version/s: 2.5.4
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None
    • Environment:
      Eclipse 3.4 Ganymede

      Description

      Hi Everybody i try to connect my spatial db which was created on oracle 11g...
      i have to following oracleConnection.properties file:
      #

      1. Properties needed to connect to Oracle
      1. Must be the string
        dbtype=oracle
      1. Machine name or IP address to connect to
        host=myhost
      1. Port number to connect to, default 1521
        port=1521
      1. The database schema to access
        schema = SPATIAL_ANKARA_YOLLAR
        database=ORACLE
      1. User name and password
        user=myname
        passwd=mypass

      And my java code is going here:

      Reader okuyucu = new FileReader("C:
      Documents and Settings\\ilitheblack\\Belgelerim
      " +
      "EclipseCalismaAlani\\BitirmeProjesi\\SpatialDataManipulation\\src\\main
      java" +
      "
      oracleConnection.properties");
      Properties config = new Properties();
      config.load(okuyucu);
      SpatialUtilities.veriDeposu = DataStoreFinder
      .getDataStore(config);

      but it always returns null datastore....

        Activity

        Hide
        Andrea Aime added a comment -
        Did you add the Oracle JDBC driver to the classpath?
        Show
        Andrea Aime added a comment - Did you add the Oracle JDBC driver to the classpath?
        Hide
        İlker GÜRCAN added a comment -
        M8 the oracle jdbc driver has alread been added to classpath of my project as a maven dependency...
        <dependency>
            <groupId>com.oracle</groupId>
            <artifactId>ojdbc14</artifactId>
            <version>10.2.0.3.0</version>
        </dependency>

        and in my business delegate classes this jar file works fine....
        Show
        &#304;lker GÜRCAN added a comment - M8 the oracle jdbc driver has alread been added to classpath of my project as a maven dependency... <dependency>     <groupId>com.oracle</groupId>     <artifactId>ojdbc14</artifactId>     <version>10.2.0.3.0</version> </dependency> and in my business delegate classes this jar file works fine....
        Hide
        &#304;lker GÜRCAN added a comment -
        Thx everybody i have solved my problem by jar file called gt-oracle-spatial-2.5-RC1.jar... i recommend this jar file and its sources to everyone who wants to connect to oracle 10g and 11g spatial DB...
        Show
        &#304;lker GÜRCAN added a comment - Thx everybody i have solved my problem by jar file called gt-oracle-spatial-2.5-RC1.jar... i recommend this jar file and its sources to everyone who wants to connect to oracle 10g and 11g spatial DB...
        Hide
        &#304;lker GÜRCAN added a comment -
        i would like to ask one more question about db tables...How can we understand whether a table has spatial data or not? i get all the table names in the schema by getTypeNames() method but then how to understand whether my table has spatial data or not?
        THX FOR YOUR FUTURE REPLIES IN ADVANCE...
        Show
        &#304;lker GÜRCAN added a comment - i would like to ask one more question about db tables...How can we understand whether a table has spatial data or not? i get all the table names in the schema by getTypeNames() method but then how to understand whether my table has spatial data or not? THX FOR YOUR FUTURE REPLIES IN ADVANCE...

          People

          • Assignee:
            Unassigned
            Reporter:
            &#304;lker GÜRCAN
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: