FetchXMLBuilder icon indicating copy to clipboard operation
FetchXMLBuilder copied to clipboard

View layout not show attribute in the view

Open Titoleto opened this issue 3 years ago • 6 comments

When I add an attribute in the fetch, the option to show attribute in the view is unchecked by default sometimes, but if I select to display it in the view, I don't know why, when executing the query, it is unchecked and the attribute is not shown. It also happens when I add a relation and try to include some attribute of the relation, it does not show me the attribute

Titoleto avatar Aug 22 '22 10:08 Titoleto

Aahh... I've tried to fix this for a while. Yes, I know it's there. But I don't really see the pattern. Please add more info, if you find any! 🙏

rappen avatar Aug 22 '22 13:08 rappen

I have several examples of when this issue is occurring, one is an aggregate query and one is not, both have link-entity. In both cases, there are attributes missing from the results. <fetch aggregate="true"> <entity name="esdc_role"> <attribute name="esdc_name" alias="Role" groupby="true" /> <link-entity name="esdc_roletracking" from="esdc_role" to="esdc_roleid"> <attribute name="esdc_headcount" alias="Headcount" aggregate="count" /> <filter> <condition attribute="esdc_headcount" operator="eq" value="1" /> </filter> </link-entity> </entity> </fetch> Results Only the "esdc_name" (alias Role) column appears.

Example 2: <fetch> <entity name="role"> <attribute name="name" /> <link-entity name="systemuserroles" from="roleid" to="roleid" intersect="true"> <attribute name="systemuserid" /> <link-entity name="systemuser" from="systemuserid" to="systemuserid" intersect="true"> <attribute name="domainname" /> <attribute name="fullname" /> </link-entity> </link-entity> </entity> </fetch> Results: Only 'name' column appears

In both cases, I was able to run these queries as SQL and received the correct results

jdpottle avatar Oct 07 '22 11:10 jdpottle

It's not clear at all, I shall improve it, but can you please add an Alias to each link-entity? When using the Layouts, it is needed to be able to show these related attributes.

rappen avatar Oct 08 '22 08:10 rappen

I'll give that a try and report back to you

On Sat, Oct 8, 2022, 6:05 a.m. Jonas Rapp @.***> wrote:

It's not clear at all, I shall improve it, but can you please add an Alias to each link-entity? When using the Layouts, it is needed to be able to show these related attributes.

— Reply to this email directly, view it on GitHub https://github.com/rappen/FetchXMLBuilder/issues/771#issuecomment-1272266812, or unsubscribe https://github.com/notifications/unsubscribe-auth/ASPRNG7ECREO7PLAK6G653TWCEW4FANCNFSM57HGEIMQ . You are receiving this because you commented.Message ID: @.***>

jdpottle avatar Oct 08 '22 09:10 jdpottle

Adding the alias to the link entity worked for me. thanks!

BennyCodeCodeMan avatar Oct 12 '22 05:10 BennyCodeCodeMan

Adding the link-entity alias worked for me, too. Thanks!

On Wed, Oct 12, 2022, 2:41 a.m. Ben Brown @.***> wrote:

Adding the alias to the link entity worked for me. thanks!

— Reply to this email directly, view it on GitHub https://github.com/rappen/FetchXMLBuilder/issues/771#issuecomment-1275597478, or unsubscribe https://github.com/notifications/unsubscribe-auth/ASPRNG7G4R335JQS7Y236RLWCZB7RANCNFSM57HGEIMQ . You are receiving this because you commented.Message ID: @.***>

jdpottle avatar Oct 12 '22 08:10 jdpottle

Related issues: #775, #803, #804, #819

rappen avatar Oct 29 '22 07:10 rappen

Added these warnings:

image

rappen avatar Nov 17 '22 15:11 rappen

Closing this now - please reopen if there is more to fix! Or create a new issue.

rappen avatar Nov 17 '22 15:11 rappen