内部连接正在破坏 SSRS
Inner join is breaking SSRS
我有一个问题:
SELECT systemuser.fullname AS 'fullname',
usersettings.calendartype AS 'calendartype',
usersettings.uilanguageid AS 'uilanguageid'
FROM filteredsystemuser AS systemuser
INNER JOIN filteredusersettings AS usersettings
ON systemuser.systemuserid = usersettings.systemuserid
inner join vfinduserguid vfg
on systemuser.systemuserid = vfg.userguid
我已将其转换为 FetchXML:
<fetch mapping="logical">
<entity name="systemuser">
<attribute name="fullname" alias="fullname" />
<link-entity name="usersettings" to="systemuserid" from="systemuserid" alias="usersettings" link-type="inner">
<attribute name="calendartype" alias="calendartype" />
<attribute name="uilanguageid" alias="uilanguageid" />
<link-entity name="vfinduserguid" to="systemuserid" from="userguid" alias="vfg" link-type="inner" />
</link-entity>
</entity>
</fetch>
使用此服务:http://www.sql2fetchxml.com/
当我尝试在 SSRS 中使用此 FEtchXML 时,我得到:
Microsoft Dynamics CRM 中不存在特定记录类型。
我做错了什么?
请注意,是最后一个连接 (vfinduserguid) 破坏了它。这个对象是一个视图。
这里是获取当前用户的方法:
<fetch version="1.0" output-format="xml-platform"
mapping="logical" distinct="false">
<entity name="systemuser">
<attribute name="fullname" />
<attribute name="systemuserid" />
<order attribute="fullname" descending="false" />
<filter type="and">
<condition attribute="systemuserid"
operator="eq-userid" />
</filter>
</entity>
</fetch>
http://crmtipoftheday.com/2014/01/09/reflecting-current-user-ssrs/
我有一个问题:
SELECT systemuser.fullname AS 'fullname',
usersettings.calendartype AS 'calendartype',
usersettings.uilanguageid AS 'uilanguageid'
FROM filteredsystemuser AS systemuser
INNER JOIN filteredusersettings AS usersettings
ON systemuser.systemuserid = usersettings.systemuserid
inner join vfinduserguid vfg
on systemuser.systemuserid = vfg.userguid
我已将其转换为 FetchXML:
<fetch mapping="logical">
<entity name="systemuser">
<attribute name="fullname" alias="fullname" />
<link-entity name="usersettings" to="systemuserid" from="systemuserid" alias="usersettings" link-type="inner">
<attribute name="calendartype" alias="calendartype" />
<attribute name="uilanguageid" alias="uilanguageid" />
<link-entity name="vfinduserguid" to="systemuserid" from="userguid" alias="vfg" link-type="inner" />
</link-entity>
</entity>
</fetch>
使用此服务:http://www.sql2fetchxml.com/
当我尝试在 SSRS 中使用此 FEtchXML 时,我得到:
Microsoft Dynamics CRM 中不存在特定记录类型。
我做错了什么?
请注意,是最后一个连接 (vfinduserguid) 破坏了它。这个对象是一个视图。
这里是获取当前用户的方法:
<fetch version="1.0" output-format="xml-platform"
mapping="logical" distinct="false">
<entity name="systemuser">
<attribute name="fullname" />
<attribute name="systemuserid" />
<order attribute="fullname" descending="false" />
<filter type="and">
<condition attribute="systemuserid"
operator="eq-userid" />
</filter>
</entity>
</fetch>
http://crmtipoftheday.com/2014/01/09/reflecting-current-user-ssrs/