What can I do to build a model for a Related database table?

1269
9
06-11-2019 11:52 PM
AyokunleAdebisi
New Contributor III

Hello. I am using model builder to solve spatial questions of a related database table but confuse as tools required to run in order to get my output for a question like : "What is the total sum of a single tree specie at a specific location in a particular year". I will build a back-end like GUI through the model through which the user can interact with to select the specie, location, and the year which will give output of the numbers. I hope you get what I am trying to say. Thanks. I need the tools to run the model of that type. this is the related table. Selection of one feature shows the related data..

0 Kudos
9 Replies
curtvprice
MVP Esteemed Contributor

I have deleted your previous posts. There is no benefit to re-posting a question that has not been answered.

curtvprice
MVP Esteemed Contributor

Relates are not directly supported, they are an interactive thing when viewing data tables and used to migrate selections across tables.

You may get a response if you provide a more clear example of what you are trying to do with example data.

0 Kudos
AyokunleAdebisi
New Contributor III

Thanks for you quick response

I have shapefile which contains about 82 locations which is a polygon shapefile (Table 1).

I have another database table of over 50years data which contains over 70,000 data of bird species distribution, types of bird species, category, year/month etc (Table 2: that contains additional information that is not in table 1.). All in the geodatabase table.

Table 1 which is the attribute of the shapefile table was related with table 2.

So now, at this stage what I am supposed to do is the use a model builder to build a tool to answer the spatial questions like:

At a Single location what is the total sum of birds in a particular year, in a particular month.

Because the birds are also grouped into categories: so questions like total sum of one category, yearly and monthly sum at a particular location or all locations.

Total sum of one specie at all location, yearly sum of one specie at all locations.

The tool will form a GUI for users to select from a drop down list of each parameters location of interest, specie of interest, category of interest. To be published as a web geoprocessing service that will enable users to carry out simple geoprocessing or spatial analysis query.

Below is the usual selection by attribute by clicking of a location the shapefile database table which shows the related data in the species database table.

0 Kudos
AyokunleAdebisi
New Contributor III

In case that is still not clear enough. Please let me know the specifics, so i can give more explanation.

0 Kudos
AyokunleAdebisi
New Contributor III

Hello Curtis,..I want to question my related database table by building a model in the arcgispro modelbuilder. 

0 Kudos
curtvprice
MVP Esteemed Contributor

You can probably make progress with this using the Add Join tool in the other direction. Relates are not supported in Model Builder.

See Select Related Data in Model Builder

AyokunleAdebisi
New Contributor III

Thanks for your response. I have been able to solve the problem to an extent by removing the relate and using the 'make query table' tool to solve the problem.

I will like to now trigger use input so as to input their any value out of the available values of the field.

0 Kudos
curtvprice
MVP Esteemed Contributor

You cannot do this with ModelBuilder, to get a custom list you need to do parameter validation.

One approach to this would be write a small Python script that imports the toolbox and calls the model after doing parameter validation.

0 Kudos
AyokunleAdebisi
New Contributor III

Ok. Thanks for all the help so far. I joined my tables to a single table since related db is not working well in model-builder..However I want to progress by asking which tools are best to combine in a model builder to answer my questions:

At a Single location what is the total sum of birds in a particular year, in a particular month.

Because the birds are also grouped into categories: so questions like total sum of one category, yearly and monthly sum at a particular location or all locations.

Total sum of one specie at all location, yearly sum of one specie at all locations.

I just want to build a model to answer this questions from my database. After which I will extend and add more functionalities using python. 

Thanks for your quick response.

0 Kudos