скрипт 1 basemap
Code
declare @id int
INSERT INTO [GisDbMain].[dbo].[BaseMap]
([Name]
,[MinLongitude]
,[MinLatitude]
,[MaxLongitude]
,[MaxLatitude]
,[EngineType]
,[InitializationData]
,[BasePath]
,[DeploymentSide]
,[Copyright])
SELECT [Name]
,[MinLongitude]
,[MinLatitude]
,[MaxLongitude]
,[MaxLatitude]
,[EngineType]
,[InitializationData]
,[BasePath]
,[DeploymentSide]
,[Copyright]
FROM [GisDbMain].[dbo].[BaseMap]
where id=1
set @id= @@IDENTITY
update [GisDbMain].[dbo].[BaseMap]
set name='google2',
[EngineType]='Google',
[InitializationData]='<!--?xml version="1.0" encoding="utf-8"?--> <TileRenderer> <copyright>(c) Google</copyright> <urlTemplates> <urlTemplate>http://mt.google.com/vt?x={XTILE}&y={YTILE}&z={ZOOM}&hl=ru</urlTemplate> </urlTemplates> <tileCacheFolder>C:\GisPlatform\Server\TileCache\Google1</tileCacheFolder> <tileSize width="256" height="256" /> <zoom min="1" max="18" /></TileRenderer>'
where id=@id
print @id
GO
скрипт 2 Map
Code
declare @idmap int
INSERT INTO [GisDbMain].[dbo].[Map]
([ParentID]
,[Name]
,[MinLongitude]
,[MinLatitude]
,[MaxLongitude]
,[MaxLatitude])
SELECT [ParentID]
,[Name]
,[MinLongitude]
,[MinLatitude]
,[MaxLongitude]
,[MaxLatitude]
FROM [GisDbMain].[dbo].[Map]
where id=1
set @idmap= @@IDENTITY
update [GisDbMain].[dbo].[Map]
set name='google'
where id=@idmap
print @idmap
GO
скрипт 3 свзяь map с basemap
Code
INSERT INTO [GisDbMain].[dbo].[Map_BaseMap]
([MapID]
,[BaseMapID]
,[Priority])
VALUES
(9
,7
,0)
GO
скрипт 4 последняя замена
Code
update [GisDbMain].[dbo].[BaseMap]
set [InitializationData]='<!--?xml version="1.0" encoding="utf-8"?--> <TileRenderer> <copyright>(c) Google</copyright> <urlTemplates> <urlTemplate>http://mt.google.com/vt?x={XTILE}&y={YTILE}&z={ZOOM}&hl=ru</urlTemplate> </urlTemplates> <tileCacheFolder>C:\GisPlatform\Server\TileCache\Google1</tileCacheFolder> <tileSize width="256" height="256" /> <zoom min="1" max="18" /></TileRenderer>'
where id=7
GO