Table of Contents


Using the Entity Browser

The Entity Browser provides comprehensive, read-only access to the Magentrix data model including all standard and custom entities, field definitions, data types, relationships, and schema metadata available within the organization's portal. This integrated reference tool enables developers to explore entity structures, understand data model connections, verify field names and types, and insert accurate field references into code without leaving the development environment or consulting external documentation.

Understanding Entity Browser capabilities, navigation patterns, relationship visualization, and field insertion features enables efficient code development with accurate entity and field references while reducing errors caused by incorrect field names, case-sensitivity issues, or misunderstood data model relationships.

Understanding the Entity Browser

Purpose and Functionality

The Entity Browser serves as an authoritative, always-accessible reference for the Magentrix data model during development activities. Developers reference the Entity Browser to verify exact entity and field API names, understand field data types and characteristics, explore relationship structures between entities, identify child relationships and related entities, discover available fields for queries and data manipulation, and ensure code references use correct case-sensitive naming.

Integrated Access: The Entity Browser is permanently available in the IDE sidebar, providing immediate access to schema information without requiring navigation to administrative setup menus, external documentation, or separate database tools.

Read-Only Reference: The Entity Browser provides read-only access to entity schema information. Developers cannot modify entity definitions, create new fields, change field properties, or alter relationships through the Entity Browser. Entity schema modifications require access to administrative setup interfaces outside the IDE.

Authoritative Source: The Entity Browser displays the actual entity schema as configured in the organization's Magentrix instance, ensuring that displayed information accurately reflects available entities, fields, and relationships rather than generic documentation that may not match the specific configuration.

Accessing the Entity Browser

Navigate to the Entities section in the sidebar navigation tree. This dedicated section appears alongside other IDE sections including Pages, Templates, Controllers & Classes, Triggers, Static Assets, and Labels.

Expand the Entities section if necessary to display the complete list of available entities. The entity list includes all standard Magentrix entities and custom entities defined for the organization.

Persistent Availability: The Entities section remains accessible throughout IDE sessions regardless of which files are open in the editor. Developers can reference entity information while editing controllers, classes, triggers, or pages without closing or navigating away from active work.

Entity List Organization

The Entity Browser displays entities in alphabetical order by entity API name, enabling predictable location of specific entities through alphabetical scanning or search functionality.

Standard Magentrix Entities: Magentrix platform provides standard entities for standalone portals or HubSpot-connected implementations. When Magentrix operates as a standalone portal or connects to HubSpot, standard Magentrix entities like Account, Contact, Opportunity, Case, and other business objects are available for data management and customization.

CRM Integration Entities: When Magentrix connects to Salesforce or Microsoft Dynamics 365, the platform imports CRM entities from the connected system. Imported entities include the CRM's Account, Contact, Opportunity, Lead, Case, and other standard CRM objects. These imported CRM entities replace Magentrix's standard entities for CRM-connected implementations, ensuring data consistency with the external CRM system.

Custom Entities: Custom entities created through Magentrix administrative setup appear in the entity list with API names that include the __c suffix. For example, creating a custom entity named "CallList" results in an API name of CallList__c. The __c suffix distinguishes custom entities from standard platform entities and indicates entities created specifically for organizational requirements.

Custom Entity Identification: The __c suffix provides immediate visual identification of custom entities in the Entity Browser. When reviewing entity lists or writing code, the suffix clearly indicates which entities are custom implementations rather than standard platform or CRM objects.

Integration Context Awareness: Understanding whether the portal connects to an external CRM system or operates standalone helps developers identify which entity sources are active. Standalone and HubSpot-connected portals use Magentrix standard entities, while Salesforce and Microsoft Dynamics integrations use imported CRM entities alongside custom Magentrix entities.

Searching for Entities

Search Functionality

The Entities section includes a search field that enables quick location of specific entities without manual scrolling through the complete entity list. Search functionality becomes particularly valuable when working with large data models containing numerous standard and custom entities.

Search Field Location: The search field appears at the top of the Entities section in the sidebar, above the entity list. The field accepts text input and filters the displayed entity list dynamically as search terms are entered.

Real-Time Filtering: As text is entered in the search field, the entity list filters automatically to display only entities whose names contain the entered text. Filtering occurs in real-time without requiring search button clicks or enter key presses.

Case-Insensitive Search: Entity search operates in a case-insensitive manner, matching entities regardless of the capitalization used in search terms. Searching for "contact," "Contact," or "CONTACT" produces identical results.

Search Strategies

Partial Name Search: Enter any portion of an entity name to locate matching entities. Searching for "Account" finds Account, AccountTeamMember, PartnerAccount, and any other entities containing "Account" in their names.

Prefix Search: Enter the beginning of entity names to locate entities with specific prefixes. Organizations using custom entity prefixes can quickly locate their custom entities by searching for the prefix pattern.

Clearing Search: Clear the search field to restore the complete entity list. Most search implementations provide a clear button (X icon) within the search field for quick search clearing.

Sequential Refinement: Start with broad search terms and refine progressively by adding characters to narrow results. This approach helps when uncertain of exact entity names or when exploring related entities.

Exploring Entity Structures

Expanding Entities

Click the expansion arrow or triangle icon next to any entity name in the entity list to expand that entity and display its complete field list, data types, and relationship information.

Field List Display: Expanded entities display all fields defined on that entity organized in a list structure. Fields appear with their API names and may include visual indicators showing field types or characteristics.

Collapsing Entities: Click the expansion arrow again on an expanded entity to collapse the field list and hide entity details. Collapsing entities that are not currently relevant reduces visual clutter and focuses attention on entities under active review.

Multiple Simultaneous Expansion: The Entity Browser supports expanding multiple entities simultaneously, enabling comparison of field structures across different entities or reference to multiple entity schemas while writing code that accesses multiple entities.

Viewing Field Information

Each field listed under an expanded entity displays the field's API name as it must be used in code references. Field names appear exactly as they are defined in the entity schema with correct capitalization that must be matched in code.

Field Names: Field API names displayed in the Entity Browser represent the exact names that must be used in controller code, class methods, trigger logic, and query statements. Case-sensitive accuracy is required for proper field access.

Field Type Indicators: Fields may display visual indicators or icons identifying field types such as text fields, number fields, date/datetime fields, boolean (checkbox) fields, picklist fields, lookup relationship fields, and master-detail relationship fields.

Standard vs. Custom Fields: Standard platform fields and custom fields created through administrative setup appear together in the field list. Custom fields often include organizational prefixes or naming patterns that distinguish them from standard fields.

Understanding Field Types

The Entity Browser displays or indicates field data types, enabling developers to understand appropriate usage patterns, comparison operators, and value formats for each field.

String Fields: Text-based fields including short text, long text, email, phone, URL, and other string types. String fields require quote delimiters for literal values and support string manipulation functions in queries and code.

Numeric Fields: Number fields including integers, decimals, currency, and percent types. Numeric fields support mathematical operations, numeric comparisons, and aggregate calculations in code and queries.

Date and DateTime Fields: Temporal fields storing dates, date/time combinations, or time values. Date fields require ISO 8601 format in queries and support date arithmetic and comparison operations in code.

Boolean Fields: Checkbox fields storing true/false values. Boolean fields use lowercase true and false keywords in Magentrix SQL queries and standard C# boolean operators in controller and class code.

Picklist Fields: Fields with predefined value lists. Picklist fields store selected values as strings and require exact value matching when filtering or comparing in code.

Lookup and Master-Detail Relationship Fields: Fields that reference records in other entities. Relationship fields enable dot notation traversal to access fields from related records in queries and code.

Understanding Relationships

Viewing Field Relationships

When reviewing field lists under expanded entities, relationship fields appear with distinctive indicators showing they reference other entities rather than storing simple data values.

Relationship Field Names: Relationship fields typically use the related entity name or a descriptive name indicating the relationship purpose (e.g., "Account" for the Contact-to-Account relationship, "Owner" for record ownership relationships).

ID Fields vs. Relationship Fields: Most relationships include both an ID field (e.g., "AccountId") storing the foreign key value as a string, and a relationship field (e.g., "Account") providing object access to the related record. Both can be used in code depending on requirements.

Relationship Navigation: Relationship fields enable dot notation access to fields on related records. For example, when querying Contacts, developers can access Account fields through the Account relationship using syntax like "Account.Name" or "Account.Industry."

Exploring Child Relationships

Expand the Child Relationships section under any entity to display all entities that reference the current entity through lookup or master-detail relationships. Child Relationships visualization helps developers understand which entities link to the current entity and what related data can be accessed.

Relationship Discovery: Child Relationships display shows entity names that have relationship fields pointing to the current entity. For example, expanding Contact Child Relationships shows entities like Case, Opportunity, and custom entities that have Contact lookup fields.

Bidirectional Understanding: While field lists show "parent" relationships (relationships from the current entity to other entities), Child Relationships show "child" relationships (relationships from other entities to the current entity). Understanding both directions enables complete data model comprehension.

Related Data Access: Child Relationships information helps developers understand available related data when querying or manipulating records. Knowing which entities reference an Account enables querying for all related Contacts, Cases, Opportunities, and custom entity records associated with that Account.

Relationship Visualization Benefits

Data Model Comprehension: Exploring entity relationships through the Entity Browser builds comprehensive understanding of data model connections, enabling developers to design queries that efficiently retrieve related data and implement business logic that properly considers entity relationships.

Query Construction: Understanding relationships enables construction of efficient queries that use relationship traversal to access related entity fields without requiring separate queries or complex join operations.

Validation Logic: Relationship understanding supports implementation of validation logic that verifies related record existence, checks related record values, or enforces business rules across entity boundaries.

Inserting Field Names into Code

Automatic Field Insertion

The Entity Browser provides automatic field name insertion functionality that places exact field API names into open code files at the current cursor position, eliminating manual typing and ensuring correct case-sensitive field references.

Error Reduction: Automatic insertion prevents typographical errors, case-sensitivity mistakes, and incorrect field name variations that cause compilation errors or runtime failures. Inserted names are guaranteed to match exact entity schema definitions.

Efficiency Improvement: Direct insertion from the Entity Browser accelerates development by eliminating the need to memorize field names, manually type long field names, or switch between reference documentation and code editor.

Insertion Process

Open a Controller, Class, Trigger, or Active Page in the editor to display the code editing interface. Position the text cursor at the location where the field name should appear in the code.

Navigate to the Entities section in the sidebar and expand the entity containing the desired field. Locate the target field in the field list displayed under the expanded entity.

Right-click on the field name to display the context menu. Select the insertion option from the context menu (the exact menu item text may be "Insert" or "Insert Field Name" depending on IDE configuration).

The IDE automatically inserts the field API name at the current cursor position in the open code file. The inserted name includes correct capitalization matching the entity schema exactly.

Insertion Context

Supported File Types: Field name insertion works with Controllers, Classes, Triggers, and Active Pages. Any code file where entity field references are appropriate supports automatic field insertion from the Entity Browser.

Code Context Awareness: Inserted field names are plain text without additional syntax. Developers must ensure the cursor is positioned appropriately within code syntax so inserted names fit correctly into expressions, assignments, or query statements.

Relationship Field Insertion: Both relationship fields and ID fields can be inserted. Insert relationship field names when using dot notation to access related records, and insert ID field names when working with foreign key values directly.

Insertion Examples

Query Field Lists: When constructing Magentrix SQL queries, insert field names into the SELECT clause field list:

SELECT Id, Name, [insert field from Entity Browser], CreatedOn FROM Contact

WHERE Clause Conditions: Insert field names into query WHERE clauses for filtering conditions:

SELECT Id, Name FROM Account WHERE [insert field] = "value"

Controller Field Access: Insert field names when accessing or assigning record field values in controller code:

string value = record.[insert field];
record.[insert field] = newValue;

Relationship Traversal: Insert relationship field names when accessing related entity fields:

string accountName = contact.[insert relationship field].Name;

Entity Browser Navigation Patterns

Efficient Entity Location

Alphabetical Scanning: For entities near the beginning or end of the alphabet, scroll through the entity list to locate desired entities. Alphabetical organization enables predictable location when entity names are known.

Search-First Approach: When uncertain of exact entity names or when working with entities in the middle of large alphabetical lists, use search functionality first to narrow the entity list before browsing.

Recent Entity Memory: The Entity Browser may maintain expanded state for recently viewed entities across IDE sessions. Return to previously expanded entities quickly without re-searching or re-expanding.

Multi-Entity Workflows

Comparative Analysis: Expand multiple related entities simultaneously to compare field structures, understand relationship mappings, or verify consistent field naming across entities.

Relationship Following: When viewing a relationship field on one entity, expand the related entity to view available fields that can be accessed through dot notation traversal. This pattern enables efficient exploration of multi-entity query possibilities.

Schema Documentation: Use the Entity Browser as an interactive schema documentation tool when planning development work, designing data models, or explaining data structures to team members.

Field Reference Best Practices

Verification Before Coding

Pre-Coding Verification: Before writing code that accesses entity fields, verify field names in the Entity Browser to ensure correct spelling, capitalization, and existence. Pre-coding verification prevents compilation errors and reduces debugging time.

Data Type Confirmation: Review field data types in the Entity Browser before implementing logic that processes field values. Understanding data types ensures appropriate operators, functions, and value formats are used in code.

Relationship Validation: Confirm that expected relationships exist and understand their direction before writing code that traverses relationships. Relationship validation prevents logic errors and ensures code accesses related data correctly.

Handling Case Sensitivity

Exact Case Matching: Entity and field names in Magentrix are strictly case-sensitive. Use the Entity Browser as the authoritative reference for correct capitalization rather than relying on memory or assumptions.

Copy-Paste Alternative: When automatic insertion is not convenient, copy field names directly from the Entity Browser display and paste them into code. Copying ensures exact case matching without manual retyping.

Compilation Error Resolution: When compilation errors indicate unknown entities or fields, immediately verify names in the Entity Browser. Case-sensitivity issues are common causes of compilation errors that are quickly resolved through Entity Browser verification.

Relationship Usage Patterns

ID Field vs. Relationship Field: Understand when to use ID fields versus relationship fields in code. Use ID fields when only the foreign key value is needed or when assigning relationships. Use relationship fields when accessing related record data through dot notation.

Null Relationship Handling: Remember that relationship fields can be null when no related record exists. Implement null checks before accessing fields through relationship traversal to prevent null reference exceptions.

Performance Considerations: Relationship traversal in queries and code may involve database joins or additional queries. Consider performance implications when designing logic that accesses multiple levels of related entities.

Entity Browser Limitations

Read-Only Access

The Entity Browser provides reference access only without modification capabilities. Developers cannot create new entities, add fields, modify field properties, change relationships, or perform any schema modifications through the Entity Browser.

Schema Changes: Entity and field modifications require access to administrative setup interfaces outside the IDE. After schema changes are made administratively, refresh or reload the IDE to ensure the Entity Browser reflects current schema definitions.

Custom Entity Creation: Creating custom entities for new business objects requires administrative entity management tools. Once created, custom entities appear in the Entity Browser for reference during code development.

Limited Metadata Display

The Entity Browser displays essential schema information including entity names, field names, field types, and relationships. Additional metadata such as validation rules, default values, or field-level permissions may not be visible in the Entity Browser.

Complete Metadata Access: For comprehensive field metadata beyond what the Entity Browser displays, access administrative entity management interfaces that show complete field definitions including all configuration options and restrictions.

Documentation Integration

The Entity Browser provides schema structure without field-level documentation or usage guidelines. Understanding field purposes, valid value ranges, business rule context, or field usage patterns may require supplementary documentation beyond Entity Browser information.

Field Purpose Documentation: Maintain external documentation describing custom field purposes, business logic associated with specific fields, field interdependencies, or usage guidelines that help developers understand when and how to use specific fields appropriately.

Relationship Documentation: Document complex relationship structures, expected relationship usage patterns, or business logic governing relationships to supplement structural information provided by the Entity Browser.

Integration with Development Workflows

Query Development

Query Construction: Use the Entity Browser to identify available fields when constructing Magentrix SQL queries in the Query Console or in controller/class code. Verify field names before writing SELECT clauses, WHERE conditions, or ORDER BY specifications.

Relationship Queries: Explore entity relationships in the Entity Browser to identify valid dot notation paths for accessing related entity fields in queries. Relationship exploration ensures queries traverse relationships correctly without attempting invalid relationship paths.

Field Type Alignment: Reference field data types in the Entity Browser when writing WHERE clause conditions to ensure appropriate comparison operators, value formats, and function calls match field types correctly.

Controller and Class Development

Data Access Logic: Reference the Entity Browser when implementing data access code in controllers and classes. Verify entity and field names before writing queries, field access statements, or data manipulation operations.

Property Type Definition: Use Entity Browser field type information to declare controller properties or class method parameters with appropriate data types matching entity field types. Type alignment prevents compilation errors and runtime type conversion issues.

Business Logic Implementation: Reference entity relationships when implementing business logic that spans multiple entities. Understanding relationship structures enables correct related record access and manipulation in business logic implementation.

Trigger Development

Trigger Context Access: When writing trigger logic, use the Entity Browser to verify exact field names on the trigger's associated entity. Correct field references ensure trigger logic accesses intended data from trigger context records.

Related Entity Access: Reference relationship structures when implementing trigger logic that reads or modifies related entities. Entity Browser exploration helps identify available relationship paths for trigger code to follow.

Field Modification Logic: Verify field data types and characteristics before implementing before trigger logic that modifies field values. Understanding field types ensures trigger modifications use appropriate value formats and types.

Troubleshooting with the Entity Browser

Compilation Error Resolution

Unknown Entity or Field Errors: When compilation errors indicate unknown entities or fields, immediately reference the Entity Browser to verify correct names and capitalization. Most unknown entity/field errors result from case-sensitivity issues or typographical mistakes.

Field Name Verification: Compare field names in error messages against field names displayed in the Entity Browser. Look for subtle differences in capitalization, spacing, or spelling that indicate naming discrepancies.

Entity Existence Confirmation: Verify that entities referenced in code actually exist in the current organization's configuration. Custom entities available in one environment may not exist in others, causing errors when code is deployed across environments.

Relationship Error Resolution

Invalid Relationship Paths: When errors indicate invalid relationship traversal, use the Entity Browser to verify that referenced relationships exist and traverse in the expected direction. Confirm relationship field names and related entity names match code references exactly.

Null Reference Errors: If runtime errors indicate null reference exceptions during relationship access, verify in the Entity Browser that relationships are optional (can be null). Add null checking logic to code that accesses potentially null relationships.

Child Relationship Understanding: When attempting to access related child records and encountering errors, review Child Relationships in the Entity Browser to confirm expected relationships exist and understand their configurations.

Data Type Issues

Type Mismatch Resolution: When compilation errors indicate type mismatches in field assignments or comparisons, reference Entity Browser field types to identify the mismatch source. Adjust code to use correct types matching field definitions.

Conversion Requirements: Identify situations where type conversions are necessary by comparing Entity Browser field types against values being assigned or compared in code. Implement appropriate conversions to align types correctly.

Query Value Format: When query results seem incorrect or queries fail, verify that literal values in WHERE clauses use formats appropriate for field data types. Date format, boolean value format, and numeric format issues are common causes of query problems.

Best Practices and Recommendations

Regular Reference During Development

Continuous Verification: Reference the Entity Browser regularly throughout development rather than relying on memory for entity and field names. Continuous verification prevents errors and reduces time spent debugging case-sensitivity issues.

Exploration Before Implementation: Explore entity structures and relationships in the Entity Browser during planning phases before writing code. Understanding available fields and relationships enables better code design and more efficient implementation.

Team Knowledge Sharing: Use the Entity Browser during code reviews and team discussions to verify shared understanding of entity structures and field names. Entity Browser reference eliminates ambiguity and ensures consistent naming across team members.

Schema Change Awareness

Post-Modification Updates: After administrative schema modifications including adding custom fields, creating custom entities, or modifying relationships, reload or refresh the Entity Browser to ensure displayed information reflects current schema state.

Environment Differences: Be aware that entity schemas may differ across development, testing, and production environments. Verify entity and field availability in target environments before deploying code that references recently added custom entities or fields.

Documentation Updates: When schema changes occur, update any external documentation referencing entity structures to maintain alignment between Entity Browser information and supplementary documentation.

Efficient Navigation

Search First Strategy: Develop a habit of using Entity Browser search functionality as the first approach to locating entities rather than scrolling through complete entity lists. Search efficiency improves as data models grow larger.

Collapsed State Management: Collapse entities after reviewing their fields to keep the Entity Browser interface focused on currently relevant entities. Collapsed state reduces visual clutter and improves navigation efficiency.

Keyboard Navigation: Learn and use keyboard shortcuts for expanding/collapsing entities, navigating field lists, and triggering field insertion when available. Keyboard efficiency accelerates Entity Browser workflows compared to mouse-only navigation.


Jump to IDE Checklist

<< Managing Static Assets | Using IDE Tools >>