Oci connection dialog, Accessing data from ms sql server, Sql server 2008 support – Pitney Bowes MapXtreme User Manual

Page 219

Advertising
background image

Chapter 11: Accessing Data from a DBMS

Accessing Data from MS SQL Server

MapXtreme v7.1

226

Developer Guide

If the Spatial column does not contain an SRID value, (the value is NULL), your MapXtreme
application is also able to interpret the data via the MapInfo Professional Coordsys defined in the
MapCatalog.

When loading tables that use the Latitude/Longitude coordinate system (Geodetic Data) to Oracle
Spatial, it is important to verify that all geometry coordinates are between (-180,180) longitude and (-
90, 90) latitude. Geodetic data coordinates beyond that range are not supported in Oracle Spatial
and may cause problems. You can check your data using MapInfo Professional before loading, or
use the Oracle Spatial SDO_GEOM.VALIDATE_LAYER() function on the table after loading it to
Oracle Spatial.

OCI Connection Dialog

The MapInfo.Data.DBMSConnectionCollection class supports a ConnectionFailed event by
subscribing to the ConnectionFailedEvent event handler. When fired, this event displays an
OCILoginDlg to give the user an opportunity to change the login information and retry the connection
to the Oracle database one additional time. This handler is specific to the MapXtreme OCI toolkit.
The event is also available through the LoadMapWizard class in the MapInfo.Windows.Dialogs
namespace.

Accessing Data from MS SQL Server

MapXtreme supports data stored in Microsoft’s SQL Server 2005, SQL Server 2008 and SQL Server
2012. The following information pertains to SQL Server 2008.

SQL Server 2008 Support

MapXtreme supports reading and writing data from and to Microsoft’s SQL Server 2008, including
the spatial data types GEOMETRY and GEOGRAPHY, along with M and Z value support for both
spatial formats.

To access data from SQL Server 2008, MapXtreme requires SQL Server Native Client 10. Data is
then handled like data from other remote database management systems that MapXtreme
supports

1

. Use the MapInfo.Data.TableInfoServer class to define the connection string and an SQL

statement to execute on the remote table. Internally, MapXtreme uses ODBC to access the remote
database.

1.

For a complete list see

Chapter 2 Supported Databases

.

Advertising