POST
|
If you need the same application to connect to Oracle and SQL Server, you can put the property values in your app.config file and read them from the application. The appsettings section would look something like this for an oracle instance with a sid of "orcl": <add key="SERVER" value="" /> <add key="DBCLIENT" value="oracle" /> <add key="DATABASE" value="" /> <add key="INSTANCE" value="sde:oracle11g:myserver/orcl" /> <!--DBMS or OSA--> <add key="AUTHENTICATION_MODE" value="DBMS" /> <add key="USER" value="myuser" /> <add key="PASSWORD" value="mypassword" /> <add key="VERSION" value="SDE.DEFAULT" /> While the same appsettings section for SQL Server might look like this: <add key="SERVER" value="myserver" /> <add key="DBCLIENT" value="SQL Server" /> <add key="DATABASE" value="mysdedatabase" /> <add key="INSTANCE" value="sde:sqlserver:myserver" /> <!--DBMS or OSA--> <add key="AUTHENTICATION_MODE" value="DBMS" /> <add key="USER" value="myuser" /> <add key="PASSWORD" value="mypassword" /> <add key="VERSION" value="dbo.DEFAULT" />
... View more
08-15-2018
01:17 PM
|
0
|
0
|
1167
|
POST
|
I have a feature service that includes about 100 tables. I can query these tables using subqueries because I have standardizedQueries set to false. In most cases, the subqueries work fine, but I am running into some problems with incorrect results in a couple of cases. Here is the database structure (simplified): X ObjectID - The SDE maintained object identifier XField1 - a data field Y RID - The SDE maintained object identifier XObjectID - a reference to the ObjectID in table X ZObjectID - a reference to the ObjectID in table Z Z ObjectID - The SDE maintained object identifier ZField1 - a data field These tables are versioned with SQL access enabled so I have versioned views. The data in the views looks like this (simplified): X.ObjectID X.XField1 10001 SomeValue Y.RID Y.XObjectID Y.ZObjectID 23201 10001 40801 Z.ObjectID Z.ZField1 40801 SomeOtherValue I want to find all of the Zs that are related to a particular X through my many-to-many relationship Y. In my feature service I can run queries with the following where clauses: X: XField1 = 'SomeValue' Y: XObjectID in (Select ObjectID from X_evw where XField1 = 'SomeValue') Z: ObjectID in (40801) If I run either of these two queries, I don't get any results: Z: ObjectID in (Select ZObjectID from Y_evw Where XObjectID in (Select ObjectID from X_evw where XField1 = 'SomeValue')) Z: ObjectID in (Select ZObjectID from Y_evw Where XObjectID in (10001)) However; In SQL Server, I can run any of these queries and get the results that I expect Select * from X_evw where XField1 = 'SomeValue' Select * from Y_evw Where XObjectID in (Select ObjectID from X_evw where XField1 = 'SomeValue') Select * From Z_evw where ObjectID in (40801) Select * From Z_evw where ObjectID in (Select ZObjectID from Y_evw Where XObjectID in (Select ObjectID from X_evw where XField1 = 'SomeValue')) Select * From Z_evw where ObjectID in (Select ZObjectID from Y_evw Where XObjectID in (10001)) Notice that the where clauses are exactly the same and that I am using the versioned view in all of my queries. All of the data was entered using the feature service and all of the data is in the DEFAULT version. One other key point, if I restart the feature service, or just wait around a while then re-run the queries all of my data shows up. That suggests that the site is caching the data. Caching for the service is set to "Dynamically from the data", but there is no spatial data in these tables so I don't think it should actually be caching for the feature service. Here is my current configuration: MS SQL Server 2014 SDE Geodatabase with database objects at 10.3 ArcGIS Server 10.3 Feature service published with ArcMap 10.3 Does anyone have any ideas about why the subqueries that go through the Y table would not work?
... View more
03-23-2017
01:31 PM
|
0
|
0
|
903
|
POST
|
Just a quick update on this. I moved the VM to a virtual network so I could assign a static internal IP address. Then I used "solution 2" to fix the problem and re-authorize the license; however, that still doesn't quite work. What I am finding is that the MAC Address, UMN 2 and UMN3 all change when the machine is deallocated then re-allocated. These values are available from the ArcGIS Administrator on the Machine Identifiers page. So every day that I want to use desktop, I would have to go through this process As a side note, I have another product that uses the MAC address for licensing and I was able to add a virtual MAC address by making some registry entries, but that virtual MAC address is not used in this license.
... View more
03-22-2017
07:39 AM
|
0
|
0
|
571
|
POST
|
Hi Rick, That is really good information. I'm running into this problem right now, could you provide a bit more detail on how you solved it? Background: I have an Azure VM (Classic) that I use for development work and it already has a static virtual IP. I've been running ArcGIS Server and ArcGIS Pro on it for years. I also need to develop an add-in for ArcGIS Desktop and using desktop on my local machine and connecting to my enterprise SQL geodatabase is painfully slow. The obvious answer is to put ArcGIS Desktop on my development VM so I can do my testing there. So I did that yesterday and everything appeared to work fine. Lat night (every night) the VM was shut down and deallocated so we would not be paying for time that we were not using. This morning my ArcGIS Desktop licenses are untrusted. System Configuration: Azure Classic VM Windows Server 2012 R2 64 bit Static Virtual IP Variable internal IP Static MAC address (to address a licensing issue from a different vendor) Software ArcGIS Server 10.3 ArcGIS Pro 1.4 ArcGIS Desktop 10.3 Single Use Desktop Advanced license
... View more
03-17-2017
07:04 AM
|
0
|
3
|
571
|
POST
|
Resolved, this is clean and simple and maybe this will save someone else some time. This will change the version for all of the feature classes that are in the workspace of OldVersion. Thanks to the guy at ESRI who shared this with me. private void ChangeDBVersionForDocument(IVersion OldVersion, IVersion NewVersion) { IActiveView pActiveView = ArcMap.Document.ActiveView; IMap pMap = pActiveView.FocusMap; IBasicMap pBasicMap = (IBasicMap)pMap; if (OldVersion == null || NewVersion == null) return; IChangeDatabaseVersion pChDBVer = new ChangeDatabaseVersionClass(); pChDBVer.Execute(OldVersion, NewVersion, pBasicMap); System.Runtime.InteropServices.Marshal.ReleaseComObject(pChDBVer); //notify listeners that the event was fired IMapAdmin2 pMapAdmin = (IMapAdmin2)pMap; pMapAdmin.FireChangeVersion(OldVersion, NewVersion); }
... View more
02-13-2017
01:30 PM
|
0
|
0
|
634
|
POST
|
No error message, when I debug the code it looks like it opens the default version of the parcels sublayer, and it doesn't switch the version of the parcel fabric dataset.
... View more
02-10-2017
01:48 PM
|
0
|
0
|
634
|
POST
|
Under this scenario, the project version sits one level down from Default. If the version does not exist, I can create it. Once I create it, I can switch my feature classes to use the newly created version, except for the fabric classes. I've tried changing the version of the individual feature classes and the dataset.
... View more
02-10-2017
11:44 AM
|
0
|
2
|
634
|
POST
|
I have a .net add-in for ArcGIS Desktop that helps a user set up their map document when they are starting a new project. One of the tasks that this add-in does for the user is create a version for the project (if it doesn't already exist) then switch all of the versioned layers to use that version. This works perfectly for "normal" feature classes, tables, relations etc. But it doesn't work for Parcel Fabric datasets. I haven't found any sample code that addresses this issue, does anyone have a sample that does this?
... View more
02-10-2017
11:34 AM
|
0
|
5
|
1583
|
Online Status |
Offline
|
Date Last Visited |
06-23-2023
09:58 PM
|