1.建立数据库连接

create public database link ytlink
connect to hightop identified by hightop
using '(DESCRIPTION=
(ADDRESS=(PROTOCOL=TCP)(HOST=192.168.2.137)(PORT=1521))
(CONNECT_DATA=
(SERVER = DEDICATED)(SERVICE_NAME = orcl))
)';

2.跨库查询

select * from police@ytlink

3.创建临时表空间

create temporary tablespace POLICE_TEMP --创建临时表空间
tempfile 'E:\app\Administrator\product\POLICE_TEMP.dbf'
size 50m
autoextend on
next 50m maxsize 20480m
extent management local;

4.删除表空间

drop tablespace POLICE_TEMP including contents and datafiles;--删除表空间

5.创建表空间

create tablespace POLICE --创建表空间
logging
datafile 'E:\app\Administrator\product\POLICE.dbf'
size 500m
autoextend on
next 500m maxsize 20480m
extent management local;

6.创建用户

create user hightop identified by "hightop" --创建用户并制定表空间
default tablespace POLICE
temporary tablespace POLICE_TEMP;

7.删除用户

drop user hightop cascade;--删除用户

8.用户授权

grant all privileges to hightop;--给用户授予权限

9.shp上传oracle

1.shp2sdo shp文件名 表名 -i id -s 4326 -d(在shp2sdo所在路径下执行)
2.SQL> @J:\DY\表名.sql(在plsql的sql命令行执行或sqlplus下执行)
3.sqlldr 用户名/密码@实例名 表名(在安装oracle机器的dos执行)
4.SQL> execute sdo_migrate.to_current('表名','geometry字段名');
5.SQL> CREATE INDEX 索引名 ON 表名(geometry字段名) INDEXTYPE IS MDSYS.SPATIAL_INDEX;

10.空间关系计算

select c.id,s.id from tlmap_village c,cameragps s where sdo_geom.relate(s.geom,'Anyinteract',c.geom,0.000001)='TRUE' --计算点在面内

11.向mdsys.cs_srs中插入crs(以3857为例):

 insert into mdsys.cs_srs (cs_name, srid, auth_srid, wktext, wktext3d)
values (
'WGS_1984_Web_Mercator_Auxiliary_Sphere',
3857,
3857,
'PROJCS["WGS_1984_Web_Mercator_Auxiliary_Sphere",GEOGCS["GCS_WGS_1984",DATUM["D_WGS_1984",SPHEROID["WGS_1984",6378137.0,298.257223563]],PRIMEM["Greenwich",0.0],UNIT["Degree",0.0174532925199433]],PROJECTION["Mercator_Auxiliary_Sphere"],PARAMETER["False_Easting",0.0],PARAMETER["False_Northing",0.0],PARAMETER["Central_Meridian",0.0],PARAMETER["Standard_Parallel_1",0.0],PARAMETER["Auxiliary_Sphere_Type",0.0],UNIT["Meter",1.0]]',
''
);

12.SDO_SRID不为NULL时,SDO_SRID必须在MDSYS.CS_SRS 表中的 SRID 列有对应的值,而且它的值必须插入USER_SDO_GEOM_METADATA视图中。

Oralce Spatial的更多相关文章

  1. oralce 10g 官方认证的操作系统版本

    oralce 10g 官方认证的操作系统版本 Operating system x86              Red Hat Enterprise Linux AS/ES 3 (Update 4 ...

  2. oracle遇到的锁异常,oralce record is locked by another user

    由于我在前不久的一次项目调试的时候,将一条数据的ID与另一条数据的ID相同了,但不知为什么没有报错,当在页面发现问题时,删除这条数据时就报错了,oralce record is locked by a ...

  3. [转]ArcIMS 中地图坐标参考设置(ArcGIS Unknown Spatial Reference)

    "ArcGIS Unknown Spatial Reference"问题: shp文件在Arcgis打开后经常因为原有坐标系无法识别而丢失信息,出现以下提示信息: "Un ...

  4. fMRI: spatial smoothing

    Source: Brain voyager support Theoretical Background Spatial smoothing means that data points are av ...

  5. AE开发实现Spatial Join Analysis

    总体网上资料不多,包括esri帮助文档都写的很简单,没有各个string参数如match_option之类的可以输入的string限制,导致在摸索中gp.Execute时报错n回. 结合网上搜集资料及 ...

  6. csc.rsp Nuget MVC/WebAPI、SignalR、Rx、Json、EntityFramework、OAuth、Spatial

    # This file contains command-line options that the C# # command line compiler (CSC) will process as ...

  7. csc.rsp Nuget MVC/WebAPI 5.0、SignalR 2.0、Rx、Json、Azure、EntityFramework、OAuth、Spatial

    # This file contains command-line options that the C# # command line compiler (CSC) will process as ...

  8. Spatial Transformer Networks(空间变换神经网络)

    Reference:Spatial Transformer Networks [Google.DeepMind]Reference:[Theano源码,基于Lasagne] 闲扯:大数据不如小数据 这 ...

  9. 【Duke-Image】Week_3 Spatial processing

    Chapter_3 Intensity Transsformations and Spatial Filtering 灰度变换与空间滤波 Intensity transformation functi ...

随机推荐

  1. CentOS vi编辑器简单备忘

    1.常用编辑命令 dd 删除(剪切)光标所在整行 5dd 删除(剪切)从光标处开始的 5 行 yy 复制光标所在整行 5yy 复制从光标处开始的 5 行 n 显示搜索命令定位到的下一个字符串 N 显示 ...

  2. BZOJ5011 & 洛谷4065 & LOJ2275:[JXOI2017]颜色——题解

    https://www.lydsy.com/JudgeOnline/problem.php?id=5011 https://www.luogu.org/problemnew/show/P4065 ht ...

  3. BZOJ3572:[HNOI2014]世界树——题解

    +++++++++++++++++++++++++++++++++++++++++++ +本文作者:luyouqi233. + +欢迎访问我的博客:http://www.cnblogs.com/luy ...

  4. python基础之魔法方法

    由于hexo自带的markdown渲染引擎对双下划线做了转义,在正文中看到的魔法方法前后都没有双下划线 setattr.getattr.delattr 可以拦截对对象属性的访问 setattr函数是用 ...

  5. Sightseeing(dijlstar) 计算最短路和次短路的条数

    Sightseeing Time Limit: 2000MS   Memory Limit: 65536K Total Submissions: 10004   Accepted: 3523 Desc ...

  6. windows下安装git

    1.从Git官网下载windows版本的git:http://git-scm.com/downloads 2.一般使用默认设置即可:一路next,git安装完毕! 3.但是如果这时你打开windows ...

  7. [mysql]mysql弱密码字典检测

    1.如何定义弱密码 和用户名一致 连续字符 连续数字 空密码 2.生成弱密码字典 3.检测脚本 4.结果

  8. sun.security.x509.CertAndKeyGen;找不到

    导入已有项目编译时出错,报: import sun.security.x509.CertAndKeyGen;找不到 而这个包属于sun公司的jar包.不是项目本身的问题,而是开发环境的问题. 最后原因 ...

  9. bzoj 1914: [Usaco2010 OPen]Triangle Counting 数三角形——极角排序

    Description 在一只大灰狼偷偷潜入Farmer Don的牛群被群牛发现后,贝西现在不得不履行着她站岗的职责.从她的守卫塔向下瞭望简直就是一件烦透了的事情.她决定做一些开发智力的小练习,防止她 ...

  10. lua滚动文字效果

    基本的思想都是创建一个clippingNode,将要截取的节点添加到clippingNode中,节点加上action即可. 下面是左右滚动的代码,如果是上下滚动,更简单了,只需修改Y坐标即可,都不用动 ...