Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics CRM (Archived)

Getting attribute types via SQL query

Posted on by 130

In the Dynamics 365 GUI when looking at a list of fields (attributes) under an entity, there's a column "Type" which lists values such as "Single Line of Text", "Two Options", "Option Set", "Multiple Lines of Text" etc.  I'm looking for a way to query these types via a SQL query and haven't been able to find where in the database they might be referenced.  The closest I've been able to come is: 

select XmlType
from MetadataSchema.AttributeTypes
where AttributeTypeId = AttributeView.AttributeTypeId

but these types are not quite the same as those listed in the GUI (for example, there's nothing like "multiple lines of text").  I assume these types are listed somewhere in the database as they're being returned in the GUI, but where?   

Thanks.

*This post is locked for comments

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

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,280 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,235 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans