Microsoft SQL Server is a relational database server product by Microsoft. Its primary query languages are T-SQL and ANSI SQL.

learn more… | top users | synonyms (1)

3
votes
1answer
48 views

Error when using arcpy.ArcSDESQLExecute() to connect to SQL Server - ArcGIS 10.4

I am able to connect to a MS SQL Server 2012 geodatabase with the arcpy.ArcSDESQLExecute() when using the .sde connection file pre-created in ArcGIS. I am not able to connect to a MS SQL Server 2012 ...
1
vote
0answers
35 views

Can't specify OID field in arcpy.MakeQueryLayer_management

I manage a library of query layers and have recently had the need to apply the same update to a bunch of them at once. Seems the only way to do that in python is to create new ones and apply ...
1
vote
0answers
11 views

Why does QGIS try to create spatial tables when loading into MSSQL Server?

When trying to load a layer from the QGIS layers panel or browsers panel, errors pop up that either the 'spatial_ref_sys' table or 'geometry_columns' table exists: If these tables exist already, ...
2
votes
1answer
64 views

Delete table rows in non-spatial database using arcpy

Working on a python script that does a bit of spatial analysis on a few layers, a spatial join of those layers, and then pulls data from a couple of other tables and holds them all in an in_memory ...
4
votes
1answer
43 views

Can ArcGis accept SQL field names with spaces?

Im working on an integration project that is providing data from our billing system to ArcGis. Field names can include spaces which are acceptable in SQL Server if enclosed in brackets eg: [Street ...
3
votes
1answer
34 views

Change feature class from ESRI native geometry to SQL Server geography

Original question: I have found a lot of documentation on importing and using query layers from SQL Server into ArcCatalog/ArcMap/etc. However, when you change the projection of a feature class or use ...
1
vote
2answers
37 views

Can raster maps be stored in a SQL Server spatial database?

Can raster maps be stored in a SQL Server spatial database? And if so, how? ... I'm aware of VARBINARY and FILESTREAM for images, but can only see GEOMETRIC and GEOGRAPHY for vector data
4
votes
1answer
35 views

Auto-generated field in ArcSDE for end user

The objective: Create a process where a coworker can open an .MXD, start editing, add a feature to represent a complaint, then add records in a related table to represent an inspection. Along the way, ...
0
votes
1answer
16 views

WMS of Geoserver SQL view shows nothing, however WFS works properly [closed]

I am using Geoserver to create a WMS service to serve data out of an SQL Server database. Everything works fine (WMS & WFS) untill I create an SQLView in Geoserver. The SQLView: SELECT * FROM ...
3
votes
0answers
32 views

Are there any MSSQL Licencing restrictions regarding ArcGIS Server Services

I use ArcGIS Server in conjuction with MSSQL Server 2012. According to my Database Administrator there could be licencing restrictions on the side of MSSQL when publishing Data over the web with ...
0
votes
0answers
19 views

Asp.net or MsSql Create bbox of a point proportional to image height and width

Short question is how do I create bbox dimensions that is proportional to image height and width? I'm working on a asp.net webservice to generate a map using geoserver. The parameters I have are ...
7
votes
0answers
114 views

Given two lat/longs, how can I tell if they are within 1 mile of each other?

I'm trying to implement a very efficient check to see whether two points are within a mile of each other, or not. My current approach is to compute the Haversine distance, and then check to see if ...
2
votes
0answers
46 views

Rename the output file ArcGIS

I am copying a tons of features from a file geodatabase to a database server. First I created an enterprise geodatabase connenction and after a database connection. In the first step I added a ...
0
votes
5answers
69 views

PDF Plotting from ArcGIS for Desktop?

I am experiencing a very annoying phenomenon at the moment when trying to plot an A0 PDF Plot and would be interested to hear if anyone has had a similar problem and whether there is a solution or ...
2
votes
0answers
30 views

How to properly deal with rectangles being curved on geographies?

I'm using Microsoft SQL Server to store simple data for administrative boundaries of the world (lots of polygons). I store this in a geography data type column. Afterwards I query these polygons by a ...
2
votes
0answers
48 views

The layer is not a valid layer and can not be added to the map - QGIS WFS

I created workspace, store and layer in Geoserver. Data source is SQL Server 2012. When I connected Geoserver WFS to QGIS, it worked. But when I tried to save changes to layer, it crashed with error ...
2
votes
2answers
73 views

Labeling MSSQL-Layer in QGIS 2.14

I am using QGIS 2.14 and have problems with labeling a layer. My layer is a MSSQL-Layer (from a GIS-Server) and the fieldtype I am using for labeling is a Sting (typename is nvarchar).If the string ...
1
vote
1answer
125 views

Spatial reference does not match data frame for Bing Maps

In ArcObjects I am loading Bing Maps as a base layer. It's coordinate system is esriSRProjCS3Type.esriSRProjCS_WGS1984WebMercatorMajorAuxSphere. On top of the base layer, I am trying to load points, ...
0
votes
0answers
25 views

Ignore database columns when inserting feature

I have a spatial table in MSSQL which has a "Geog" column that stores WKT and an "area" column that automatically populates based on the "Geog" geometry. This table is succesfully added in qgis and ...
0
votes
0answers
28 views

Google Earth and GeoServer as WFS-T overlay

I need to use Google Earth (Pro) as tool for editing MS SQL Server database content through GeoServer. Is there a way to connect GeoServer and Google Earth using WFS-T, or there is another way of ...
0
votes
2answers
45 views

SpatialPointsDataFrame too slow FOR LOOP

I've run into a small problem where my for loop has been running for 3.5 hrs+. I have a Geodataset in SQL Server with a field called Shape that stores co-ordinates in geometry data type. Firstly, I ...
0
votes
1answer
70 views

Read SQL Server Geometry datatype in R

I have two datasets that come from ArcGis, stored in SQL Server. I have a column called - Shape which is a geometry data type and the value looks like this: ...
2
votes
2answers
105 views

SQL Server - Select all polygons nested within a larger polygon

This is a seemingly simple SQL Server geometry question that I thought would have an out-of-the box solution, but I'm not having any luck finding one. My intent is to select all the records within ...
2
votes
1answer
37 views

How to get specific version (renedered with) of a feature layer in arcpy

Is there any way to get version of a layer loaded using arcpy.MakeFeatureLayer_management in arcpy with mssql server connection. There are tools that be used for several types of version related tasks ...
3
votes
3answers
140 views

ArcPy.da.UpdateCursor error The requested operation is invalid on a closed state

Hello I am getting an error when trying to use the arcpy.da.UpdateCursor(). The error I am receiving is as followed The requested operation is invalid on a closed state I am in the python ...
2
votes
1answer
39 views

Using specific ODBC connection when writing to SQL?

I am currently writing an output file that is generated using some Mapbasic Code into a MS SQL Database: Dim SQL_output_tablename as String SQL_output_tablename = ...
1
vote
0answers
48 views

Best SRID for worldwide data in Microsoft Sql Server geometry field?

I'm using Microsoft Sql Server 2012 to store geographical data related to hydrometeorological stations which are scattered around the globe (point layers and multipolygon layers). My data is in WGS84 ...
1
vote
2answers
66 views

Using Python to select records by date field

I am trying to write a python script to select records created within the past 7 hours (date field - database time) using a where-clause within arcpy. The table is ArcSDE database (Microsoft SQL ...
2
votes
0answers
61 views

Problem with adding non spatial view from MSSQL to QGIS

I have QGIS 2.12.3 app installed on one server (servername1) and MSSQL server database installed on servername2. The database is password protected and I have made connection successfully using QGIS ...
0
votes
1answer
52 views

Copying database view into an enterprise geodatabase?

Say I have DatabaseA, which isn't structured in a way that allows me to reference it as a geodatabase in ArcGIS. Fields have to be renamed, geometry added, etc. etc. Now, it seems to me that what I ...
1
vote
0answers
68 views

Some point features in feature class not displaying in ArcMap?

I am trying to display a point feature class, but a few features from the same data set are not displayed. Originally I have heaps of point features in a point feature class, which are well displayed ...
0
votes
0answers
126 views

Show polygon geometry from SQL Server on Google Maps

I have downloaded Canadian Postal FSA's boundaries (Like Zip boundaries in the USA) from stats Canada and I have imported the shape files in SQL Server. I want to be able to Query the Database and ...
3
votes
1answer
84 views

Mapping SQL tables in ArcGIS Desktop

I have several tables in SQL server. I am trying to visualize my data in ArcGIS. However, I have not been able to do so. I started off my making a database connection in Arc Catalog to my SQL. I did ...
1
vote
0answers
48 views

How to parameterize query sent with arcpy.ArcSDESQLExecute class [closed]

I have been developing a geoprocessor which takes user inputs as strings to develop a dynamic sql statment sent to MSSS from an ArcSDESQLExecute class. The app will only allow for controlled input, ...
0
votes
1answer
60 views

Can updates be made to “ogr_fdw” foreign tables in PostgreSQL?

I am accessing a Microsoft SQL Server table (w/ SQL Server a geometry column) via an ogr_fdw foreign table. SELECT statements work great, including the PostGIS functions that I've tried. Are UPDATES ...
0
votes
0answers
118 views

Convert XY to Lat Long using SQL?

My organization is creating a 311 mobile app. The backend is all run through SQL and report emails are generated. We are grabbing the xy from the app and then want to translate it to Lat/Long to be ...
0
votes
0answers
249 views

Failure to access the DBMS server, communication link failure

I am using ArcGIS suite 10.2 and have SSMS 2012 installed. I have a database connection through ArcSDE to a SQL database. After roughly 15mins, I am unable to add data from this database. Has anyone ...
0
votes
0answers
49 views

Automatically picking up OBJECTID in ArcMap from Create View in SQL Server

I have a plain SQL table stored in an SDE database on SQL Server 2008 as below. CREATE TABLE [dbo].[AAA_TEST]( [ID] [int] NOT NULL, [LON] [decimal](9, 6) NOT NULL, [LAT] [decimal](9, 6) ...
3
votes
0answers
47 views

QGIS MSSQL Spatial Layer Instant Crash

I am able to connect to the mssql server database and choose the table that contains the spatial data. However, as soon as the layer is added, I get the 'crash dumped' error with a message saying ...
0
votes
1answer
48 views

How to find Nearest point on line from a point cordinate in SQL server

I want to find out the nearest point on my road network which is a multiline string from a point with lat lon value. The below code I have tried for finding buffer distance line from a point. ...
0
votes
0answers
22 views

How to Find Source and target using STBuffer And STIntersects in SQL Server?

I am using this query to find the source and target from Routes table, but it's not getting the correct result SELECT TOP 1 a.target FROM Routes a WHERE ...
1
vote
1answer
56 views

Viewing list of data sets that have been edited under specific ArcSDE Version?

I'm wondering if it's possible to list all of the data sets (feature classes, tables, etc.) that have been edited under a particular version in ArcSDE. A tool that does this would be ideal (I see ...
0
votes
0answers
53 views

ArcGIS Desktop 10.3.1 Database locks

I am having difficulties with locks in my MSSQL Databases. I am trying to rename sde featureclasses and also import new ones. Although I have stopped all AGS Services I cannot seem to do simple ...
1
vote
0answers
40 views

While connecting MS SQL getting error “Data source name not found and no default driver specified QODBC3: Unable to connect”

I have used the following code for connecting the Microsoft SQL Server's database. but at the time of opening database connection it is throwing an error. Here is my code, from PyQt4.QtGui import * ...
2
votes
1answer
156 views

Should the QGIS “DB Manager” have Microsoft SQL Server as an option?

I was looking for interactive query options for SQL Server (similar to SQL Server Management Studio). The "DB Manager" works great for Postgres and I'm primarily using the Load as new layer as I build ...
4
votes
1answer
128 views

How to automate joining SQL Server non-spatial database tables to ArcGIS shapefile

I have dozens of SQL Server non-spatial database tables. These are common tables, the column types are: nvarchar, int and float. I try to use Arcpy to automate joining these database tables to ...
4
votes
1answer
138 views

STIntersection returning NULL with seemingly valid geography data

I want to include only the portion of Alaska that's in the western hemisphere. Apparently, some islands are on the other side of the international dateline. I am using STIntersection to intersect the ...
1
vote
0answers
20 views

SQL Server aggregate function in ogr2ogr command

I would like to define create a GeoJSON bounding box using SQL Server's EnvelopeAggregate function, embedded in an ogr2ogr command. I have the following command: ogr2ogr -f GeoJSON envelope.json ...
0
votes
0answers
69 views

Need to find a point a given distance along a linestring

Need to take a linestring and find a coord every x meters along the line. I tried using the SQL Server Spatial Tools and found .NET to be slow and after 5(ish) days of processing, SQL server (or .NET) ...
0
votes
1answer
38 views

ArcPy function for changing data source server properties inside mxds?

Is it possible to change the parameters highlighted in the screenshot below? If so which ArcPy function would do this? I know about and do not want to use the function that references .sde files on ...