Oracle 11gR2 - Basics..

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

Oracle 11gR2 - Basics..

Birgir
Hi,
Ive just installed Oracle 11gR2 and I need to....
create a new table
import data to that table
show the data in Mapguide.

So far I've been able to install Oracle, create the table and importing the data to that table.
Im also able to create a feature source (with KingOracle) to my Oracle database with the following connection parameters:

Username : xxxx
Password : xxxx
Service : xe
OracleSchema : "empty"
KindFdoClass : "empty"
SDE Schema : "empty"

But when I create a layer for my Oracle feature source, I recevie the following error message:
"Feature Source (Library://.....) has no usable feature classes. Choose a different feature source."

Does the error message mean that my database doesnt have a table with spatial context? if yes, what can I do to correct this?

Regards,
Birgir
Reply | Threaded
Open this post in threaded view
|

Re: Oracle 11gR2 - Basics..

simon pelicon
Hi!

Set your OracleSchema value to xxxx (you username or schema name where table with geometry is stored)

OracleSchema    : " xxxx  "


Otherwise check  USER_SDO_GEOM_METADATA view.

King.Oracle provider will read ALL_SDO_GEOM_METADATA View and find tables and columns with SDO_GEOMETRY data type.
For each pair Table-Column King.Oracle will create an FDO Feature class. 
If you want a FDO Feature class to be created based on Oracle View than you need to add a row in USER_SDO_GEOM_METADATA for that View.

Check and Update/Insert statement for USER_SDO_GEOM_METADATA for your geometry

INSERT INTO USER_SDO_GEOM_METADATA
VALUES(
'EVENTS','GEOM',
    MDSYS.SDO_DIM_ARRAY(
    MDSYS.SDO_DIM_ELEMENT('X', -180, 180, 0.000000005),
    MDSYS.SDO_DIM_ELEMENT('Y', -90, 90, 0.000000005)
     ),
  4326   -- SRID
);

You must also create Spatial  index on that geometry.

Regards,

Simon





On Thu, Jan 26, 2012 at 3:54 PM, Birgir <[hidden email]> wrote:
Hi,
Ive just installed Oracle 11gR2 and I need to....
create a new table
import data to that table
show the data in Mapguide.

So far I've been able to install Oracle, create the table and importing the
data to that table.
Im also able to create a feature source (with KingOracle) to my Oracle
database with the following connection parameters:

Username                : xxxx
Password                : xxxx
Service                 : xe
OracleSchema    : "empty"
KindFdoClass    : "empty"
SDE Schema      : "empty"

But when I create a layer for my Oracle feature source, I recevie the
following error message:
"Feature Source (Library://.....) has no usable feature classes. Choose a
different feature source."

Does the error message mean that my database doesnt have a table with
spatial context? if yes, what can I do to correct this?

Regards,
Birgir

--
View this message in context: http://osgeo-org.1560.n6.nabble.com/Oracle-11gR2-Basics-tp4340841p4340841.html
Sent from the MapGuide Users mailing list archive at Nabble.com.
_______________________________________________
mapguide-users mailing list
[hidden email]
http://lists.osgeo.org/mailman/listinfo/mapguide-users


_______________________________________________
mapguide-users mailing list
[hidden email]
http://lists.osgeo.org/mailman/listinfo/mapguide-users
Reply | Threaded
Open this post in threaded view
|

RE: Oracle 11gR2 - Basics..

djonio
In reply to this post by Birgir
Specify the _OracleSchema_ (aka - object owner)
r,
dennis
_______________________________________________
mapguide-users mailing list
[hidden email]
http://lists.osgeo.org/mailman/listinfo/mapguide-users
Reply | Threaded
Open this post in threaded view
|

Re: Oracle 11gR2 - Basics..

zspitzer
you need to flush the FDO connection to see any schema changes

either use maestro's right click option or resave the feature source which
does the same thing

z

On Fri, Jan 27, 2012 at 3:37 AM, Jonio, Dennis (Aviation)
<[hidden email]> wrote:
> Specify the _OracleSchema_ (aka - object owner)
> r,
> dennis
> _______________________________________________
> mapguide-users mailing list
> [hidden email]
> http://lists.osgeo.org/mailman/listinfo/mapguide-users



--
Zac Spitzer
Solution Architect / Director
Ennoble Consultancy Australia
http://www.ennoble.com.au
http://zacster.blogspot.com
+61 405 847 168
_______________________________________________
mapguide-users mailing list
[hidden email]
http://lists.osgeo.org/mailman/listinfo/mapguide-users
Reply | Threaded
Open this post in threaded view
|

Re: Oracle 11gR2 - Basics..

Birgir
In reply to this post by simon pelicon
Hi Simon,
Ive solved the problem....

My problem was, when I exported the data from the Oracle database all the columns became varchar2.
I fixed that by exporting the tabel to .xsl and then I followed this example
http://www.adamestrada.net/2010/01/oracle-spatial-and-user_sdo_geom_metadata/

and now it works.

thanks for you help!

Regards,
Birgir