Alright, I understand delegation can be a problem, and I think I understand why.
My issue is understanding best practices to avoid delegation issues.
My current situation is I have a Company (Accounts in the CDM) table, which has related records in a Sites table, which has related records in a SiteAddress table.
I would use a tree control, but as we don't have the control, I decided to use tablists.
First tablist shows companies, then the company sites in another tablist, and finally the Site addresses in the last tablist. (on this I would take suggestions, I do like the appearance of handling it this way, but I'm not married to it.)
SiteAddresses will cause a delegation issue due to the number of records. Right now it's less than the limit but it won't stay that way.
This code works (less the delegation issue):
I tried using AsType, but it is nothing but issues that I just don't see the issue based on examples I've found. We have Bing chat which does an OK job suggesting things and I can generally sort through. That suggested using AsType.
So, I'm looking for suggestions on how to avoid delegation issues. I considered just creating a collection locally, but that seems like a bad idea, so I'd rather do it properly.
When I try to use AsType I get a plethora of errors that I'm just not understanding, I've never used AsType, but it looks pretty straightforward.
Here is that disaster formula I can't sort out:
I am working on this myself, but I am not optimistic.
Another question I have is around the GUID comparison. I've run into this one a couple of times (issues trying to compare GUIDs) and gotten through it, but not really clear why I even have the issues at all.
The field 'ParentID' is a text field in the table Sites that stores the GUID of the record in the table Accounts the Sites record relates to. In Accounts the field is 'Account' or 'AccountID' This is the Account table in the CDM.
On this issue am I doing this wrong? I get errors requiring me to convert both to text (my solution), which is why I have the delegation issue in the first place, I think. Am I correct that if I could just make the comparison GUID to GUID and NOT use TEXT I wouldn't have a delegation issue? Am I doing something wrong... why can't I just compare GUID to GUID? Should I be handling the relation some other way?
The datasets are small enough right now I can adjust the approach now if I am doing this wrong.
OK... I guess I am a bit confused on how dataverse? handles GUID. I've run into some trouble trying to use them. It just made sense to me that I would use the GUID for a record to relate it over to another record.
I've had type issues which led to delegation issues etc.
I ended up stumbling across something, can't remember what now, that made me think we should be using some other column. Well, I have an auto-number field in every record in my tables as we import these tables from an old access app. So I just use those number and bammo, problem solved...
But if your advanced and see this I'd love to gain some understanding of what we are supposed to do with GUID fields... EG: why can't I add a GUID field to a view?
Anyway, thanks for looking.
WarrenBelz
146,524
Most Valuable Professional
RandyHayes
76,287
Super User 2024 Season 1
Pstork1
65,906
Most Valuable Professional