Quantcast
Channel: Für Entwickler: SQL Server Forum
Viewing all articles
Browse latest Browse all 1772

DB with digital cadastral map

$
0
0

I have a strange behavior with my DB.

I'm using a database with 1.800.000 lands with the dcm (Data type is geimetry - Shape format).

I attached the exactly same database on two different SQL-Servers:

  • Microsoft SQL Server 2012 - 11.0.5582.0 (X64) Feb 27 2015 18:10:15 Copyright (c) Microsoft Corporation Developer Edition (64-bit) on Windows NT 6.1 <X64> (Build 7601: Service Pack 1) (Hypervisor)
  • Microsoft SQL Server 2014 - 12.0.2548.0 (X64) Jun  8 2015 11:08:03 Copyright (c) Microsoft Corporation Standard Edition (64-bit) on Windows NT 6.3 <X64> (Build 9600: ) (Hypervisor)

If i execute an select it takes on the SQL-Server 2014 much longer...

SQL-Server 2014:  64GB RAM 1600 MHz | 16 Cores, Logical processors 32 2,60 GHz | Storage is Samsung SSD 850 Pro 1TB

SQL-Server 2012:  16GB RAM | 8 Cores 2,49GHz |

The Querys are:

SET STATISTICS TIME ON
SELECT
       shape
FROM
       its.DKM_GST
WHERE
       DKM_GST.SHAPE.STIntersects(geometry::STPolyFromText('POLYGON((70000 352000, 70200 352000, 70200 352200, 70000 352200, 70000 352000))',31255)) = 1
union all
select geometry::STPolyFromText('POLYGON((70000 352000, 70200 352000, 70200 352200, 70000 352200, 70000 352000))',31255)
SET STATISTICS TIME OFF



SET STATISTICS TIME ON
SELECT
       shape
FROM
       its.DKM_GST WITH(index(SI_DKM_GST))
WHERE
       DKM_GST.SHAPE.Filter(geometry::STPolyFromText('POLYGON((70000 352000, 70200 352000, 70200 352200, 70000 352200, 70000 352000))',31255)) = 1
union all
select geometry::STPolyFromText('POLYGON((70000 352000, 70200 352000, 70200 352200, 70000 352200, 70000 352000))',31255)
SET STATISTICS TIME OFF
  • First Select on the SQL-Server 2012: 186 ms (73 Rows)
  • Second Select on the SQL-Server 2012: 24 ms (211 Rows)
  • First Select on the SQL-Server 2014: 5332 ms (73 Rows)
  • Second Select on the SQL-Server 2014: 34 ms (211 Rows)

Select on a local database on my computer (Spec.: 24GB RAM 1333 MHz | 2 CPU's - 12 Cores, logical processors 24 3,06 GHz | Storage is Samsung SSD 850 Pro 512GB)

  • First Select on local database: 10663 ms (73 Rows)
  • Second Select on local database: 186 ms (211 Rows)

Why does it take longer on the SQL-Server 2014 as on the SQL-Server 2012? - The SQL-Server 2014 has more power...



Viewing all articles
Browse latest Browse all 1772

Latest Images

<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>