web
You’re offline. This is a read only version of the page.
close
Skip to main content
Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

what is the role of field on table"InstanceRelationType"

(0) ShareShare
ReportReport
Posted on by 30

Dear All,

what is the role of field on table"InstanceRelationType" in table Inheritance?

1.what kind of value it stored?

2. how it's work practically?

Please give me more shed on this.

Thanks!

Arpan

*This post is locked for comments

I have the same question (0)
  • Suggested answer
    Vilmos Kintera Profile Picture
    46,149 on at
    RE: what is the role of field on table"InstanceRelationType"

    Let me show you how to Google in the documentation using the site keyword in order to find answers:

    [View:http://lmgtfy.com/?q=ax+InstanceRelationType+site%3Amicrosoft.com:750:50]

  • Suggested answer
    Martin Dráb Profile Picture
    237,658 Most Valuable Professional on at
    RE: what is the role of field on table"InstanceRelationType"

    Make sure you read the documentation page Table Inheritance Overview (and child pages). It should answer your questions.

    If not, please explain what exactly you don't understand.

  • @rp@n Profile Picture
    30 on at
    RE: what is the role of field on table"InstanceRelationType"

    Thanks Martin

    I did the Table Inheritance with Two tables : 

    For example :

    1. Base Table : Fields : StudentID, RollNumber, Class

    2. Derived Table : Fields : Marks, Division

    Steps :

    1. In Base Table properties set to Support Inheritance = Yes

    2. Then creating int64 field in Base table. Name the int64 field as "InstanceRelationType".

    3. In Base table set the InstanceRelationType property to InstanceRelationType

    4. and create few other fields as needed.

    5, In Derived table , we are setting two properties Extends and Support Inheritance

    6. In extends we set "BaseTable" and Support Inheritance set to Yes

    ****

    Then i open Derived Table

    I saw the fields from Base table is automatically populated in to Derived table.

    It's showing fields in Derived table:

    StudentID, RollNumber, Class,Marks, Division 
    Note : here StudentID, RollNumber, Class fileds from base table.

    ***** Then i am creating new records in Derived table .

    Then i open Base table, i saw data is automatically replicated in the base table as we are created records in the derived table.

    Note : I noticed two things :

    InstanceRelatiponType holds "Table ID"of Base table which is also same in Derived table in field InstanceRelationType.

    I think the field InstanceRelatiponType  is used for making relation between 2 tables (Base and Derived).

    Please let me know if i missed any thing?

    Please give me more shed on this.

    Arpan

  • Suggested answer
    Martin Dráb Profile Picture
    237,658 Most Valuable Professional on at
    RE: what is the role of field on table"InstanceRelationType"

    Let me quote the documentation which I asked you to read: "The system uses a field on the TabPet base table to record the table ID of which ever derived table corresponds to each base table row. The InstanceRelationType property tells the system which field must store the table IDs."

  • @rp@n Profile Picture
    30 on at
    RE: what is the role of field on table"InstanceRelationType"

    Thanks Martin,

    Can you please let me know the above "table inheritance process"which i did is correct?

    Thanks!

    Arpan

  • @rp@n Profile Picture
    30 on at
    RE: what is the role of field on table"InstanceRelationType"

    Dear All,

    Can you please verify the above process of Table Inheritence is correct or not?

    Please give me more shed on this.

    Thanks!

    Arpan

  • DiepBH Profile Picture
    115 on at
    RE: what is the role of field on table"InstanceRelationType"

    Dear Martin,

    field InstanceRelationType store TableID, so is there any class to update InstanceRelationType field (or any field in other table store TableID) when Table ID change?

  • Martin Dráb Profile Picture
    237,658 Most Valuable Professional on at
    RE: what is the role of field on table"InstanceRelationType"

    Table ID shouldn't change. Can you explain your scenario, please?

  • DiepBH Profile Picture
    115 on at
    RE: what is the role of field on table"InstanceRelationType"

    Im looking into Table inheritance and transfer data directly by SQL. I got issue data will not map if destination database has different table ID for derived table, I can update new Table ID to base table in this situation.

    So I want to find out is there any way to get list of base table and derived table to update InstanceRelationType?

  • Martin Dráb Profile Picture
    237,658 Most Valuable Professional on at
    RE: what is the role of field on table"InstanceRelationType"

    This is just one of a long list of reasons why you shouldn't access database directly (here are some others). I strongly recommend you change your design. For example, consider using DIXF instead.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Neeraj Kumar – Community Spotlight

We are honored to recognize Neeraj Kumar as our Community Spotlight honoree for…

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

#1
Priya_K Profile Picture

Priya_K 4

#2
Alexey Lekanov Profile Picture

Alexey Lekanov 3

#3
Ivan (Vanya) Kashperuk Profile Picture

Ivan (Vanya) Kashperuk 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans