TWO PART QUESTION
I'll try to explain this as best I can.
PART 1
I have a table that looks like this:
the two last rows are identical exept for the types and UrlId.
I have a SP that I call that executes the following query to get me the data above:
SELECT Urlid, DomainName, OrgId, DomainId, s.TypeId AS TypeId
FROM DomainData d
JOIN SystemUrls s ON s.DomainId = d.Id
WHERE @OrgId IS NULL OR OrgId = @OrgId
How can I make so that the data looks like?:
Name(varchar) OrgId(bigint) DomainId(bigint) TypeId(int)
Three 556548-4499 71 2,1
PART 2
Assuming that I dont change the above result and decide to change it on the server with a linq-query(C#)
How would a linq-query look like to give me the desiered result?