adding relationship class

1353
3
05-07-2014 10:27 AM
DorotaStanczak
Deactivated User
Hello, my problem is probably easy to solve. But I don't know how and I can't find solution. It is about adding relationship class to the Map. I created relationship class between two layers in geodatabase directly (I tried also creating relationship class in feature class dataset). Everything is created correctly (cardinality - I tried one-to-one and one-to-many, primary keys etc.). I can see relationship class in Catalog tree but I can't add relationship class to the Map. I get "Could not add specified data object to the map". How can I handle this?
I think that everything is ok with geodatabase since I can create relationship class (many-to-many) between a layer and non-spatial table and add it to the View.

The layers for the problematic relationship class are empty - since this is only template for database, but that was not a problem in creating relationship class with non spatial table.

I would really appreciate some advice.

Cheers,
Dorota
0 Kudos
3 Replies
JoeBorgione
MVP Emeritus
Don't try to add the relationship class; add the two feature classes or what ever is related in the relationship class and it (the relationship class) comes with them.
That should just about do it....
0 Kudos
DorotaStanczak
Deactivated User
Thanks Joe 🙂 I knew the answer is easy but I didn't think it is as easy 😉 I checked and it works. The relationship itself is not added to the Table of Contents, but when I identify a feature in one layer I can see that it is related to a different layer 🙂
0 Kudos
JoeBorgione
MVP Emeritus
Thanks Joe 🙂 I knew the answer is easy but I didn't think it is as easy 😉 I checked and it works. The relationship itself is not added to the Table of Contents, but when I identify a feature in one layer I can see that it is related to a different layer 🙂


Same thing happened to me; struggled with the exact same thing you describe, and then had an "ah ha" moment....
That should just about do it....
0 Kudos