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

Notifications

Announcements

No record found.

Community site session details

Community site session details

Session Id :
Finance | Project Operations, Human Resources, ...
Answered

Get Table Id and Field Ids of D365 F&O Table through SQL query

(0) ShareShare
ReportReport
Posted on by 758

Hi Everyone,

Using below SQL query I can get the Table Id,

select * from SysTableIdView where Name = 'CustTable'

Can anyone please help me with SQL query to get field Ids of all fields of a particular table? This is possible and I have done this long time back, so unable to recall it.

I don't want to fetch field Id of a single field. I want the list of all field names and their IDs.

Thank you in advance.

I have the same question (2)
  • Verified answer
    nmaenpaa Profile Picture
    101,160 Moderator on at

    Try SysTableFieldIdView.

  • Rhushikesh R Profile Picture
    758 on at

    Thank you Nikolaos for quick response.

    I am able to fetch field Ids with below query now.

    select * from SysTableFieldIdView where SysTableFieldIdView.Id = '77'

    In above Query,  SysTableFieldIdView.Id (77) is a Table Id

  • André Arnaud de Calavon Profile Picture
    300,917 Super User 2025 Season 2 on at

    Hi Rhushikesh,

    A small additional comment. Note that the IDs can be different in each environment.

  • Rhushikesh R Profile Picture
    758 on at

    Hi Andre,

    Then how could we identify the IDs for UAT and Production environment? As we don't have SQL access of UAT and Production in D365, do I need to write X++ job for same?

  • Martin Dráb Profile Picture
    237,807 Most Valuable Professional on at

    Why would you do that?

    Please tell us what you're trying to achieve from business point of view. We can't suggest a meaningful technical design without knowing what you need to achieve.

  • Suggested answer
    nmaenpaa Profile Picture
    101,160 Moderator on at

    Table and field IDs are technical IDs that are intended for D365 internal usage. As long as you're working inside D365, you can use the mentioned views in x++ to get the info. And if you're working outside D365, then table and field ids should be irrelevant.

    Please let us know what is your functional requirement. Thanks!

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 > Finance | Project Operations, Human Resources, AX, GP, SL

#1
Martin Dráb Profile Picture

Martin Dráb 664 Most Valuable Professional

#2
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 522 Super User 2025 Season 2

#3
Sohaib Cheema Profile Picture

Sohaib Cheema 303 User Group Leader

Last 30 days Overall leaderboard

Product updates

Dynamics 365 release plans