Select to view content in your preferred language

Definition Query based on relate

1550
6
04-22-2019 06:55 AM
RobertBorchert
Honored Contributor

In ArcGIS Pro.  I have a point feature that contains site locations.   They each have a unique LocationID (Maximo Location to be specific) 

I have a table that is downloaded from Maximo that contains all the active Project #'s

The projects #'s table contains asset numbers and the device name.  There will be multiple unique asset numbers with the same project #

I want to be able to update Install Date and Status on the Project #'s table.

To that end I have created a relationship of 1 (Site Locations)  to many (Project #'s) based on Location.

When I start an edit session the relationship works and I can edit the fields I need to edit in the Project # table

However, I have 1606 unique sites.  I only have 26 unique location numbers in the Project # table.

I would like to know how I can create a definition query to only show the Site Locations that have a relation

It would work with a Join, but  a join will not show a many 

0 Kudos
6 Replies
KoryKramer
Esri Community Moderator

Are you sure that a join won't show the one-to-many relationship in ArcGIS Pro?  Last time I checked, this is a difference between ArcMap and ArcGIS Pro.  i.e. say you're working in a file gdb in ArcMap and have a 1:M join.  Only the first record will show in the attribute table.  However, in ArcGIS Pro, one record will show in the attribute table for each feature-joined record.  So one point feature with 10 joined records would show 10 lines in the attribute table.  Maybe that fact alone would help you accomplish what you need to in Pro?

0 Kudos
RobertBorchert
Honored Contributor

I am working in SDE with a versioned dataset.

0 Kudos
RobertBorchert
Honored Contributor

I tried a Join in Pro and it displays  [Different Values] in the fields.  You can see below as the Locations are the same it shows the Location.  

0 Kudos
KoryKramer
Esri Community Moderator

I see.  I was thinking about the attribute table itself, not the Attributes Pane.

0 Kudos
RobertBorchert
Honored Contributor

The end result is I have to get it working in Collector for field crews. If it was a matter for in office uses the user could select the table showing selected objects. 

I could work around by doing a join first and populating a field in the Sites toggle visibility but the desire is to set up a reconcile back to Maximo with updates on completed work and a new export of Project #'s.  I suppose if there is not a way to do this I will have to opt for a python script to run after the export to field calculate the visibility field 

0 Kudos
BrianBulla1
Frequent Contributor

Hi Robert Borchert

Was there ever any resolution to this?  I need to run a definition query on a layer, based on attributes in the related record.  Mine is for Watermain Breaks.  I need to query out all of the breaks (a 1:1 relate to WaterMains), where the Watermain has a LININGINSTALLDATE.

The join (in SDE, versioned) is there and working, but I just can't figure out how to write the Definition Query in ArcPro.

Also, how is your Maximo implementation going?  Did you have to write any custom code to update the MXCREATIONSTATE as you edit your data??

0 Kudos