{"action":"created","issue":{"url":"https://api.github.com/repos/dotnet/csharplang/issues/1563","repository_url":"https://api.github.com/repos/dotnet/csharplang","labels_url":"https://api.github.com/repos/dotnet/csharplang/issues/1563/labels{/name}","comments_url":"https://api.github.com/repos/dotnet/csharplang/issues/1563/comments","events_url":"https://api.github.com/repos/dotnet/csharplang/issues/1563/events","html_url":"https://github.com/dotnet/csharplang/issues/1563","id":326133723,"number":1563,"title":"Proposal: Wildcard '*' for building anonymous types (like \"select *\" in SQL)","user":{"login":"springy76","id":16399318,"avatar_url":"https://avatars2.githubusercontent.com/u/16399318?v=4","gravatar_id":"","url":"https://api.github.com/users/springy76","html_url":"https://github.com/springy76","followers_url":"https://api.github.com/users/springy76/followers","following_url":"https://api.github.com/users/springy76/following{/other_user}","gists_url":"https://api.github.com/users/springy76/gists{/gist_id}","starred_url":"https://api.github.com/users/springy76/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/springy76/subscriptions","organizations_url":"https://api.github.com/users/springy76/orgs","repos_url":"https://api.github.com/users/springy76/repos","events_url":"https://api.github.com/users/springy76/events{/privacy}","received_events_url":"https://api.github.com/users/springy76/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2018-05-24T13:55:55Z","updated_at":"2018-05-24T15:06:11Z","closed_at":null,"author_association":"NONE","body":"Example:\r\n\r\n`var anon = new { x.*, y.* };\r\n`\r\n\r\nThe compiler would only have to flatten this out to \r\n- all public properties with getters \r\n- (named) members of value tuples\r\n\r\nin an early phase of compilation (which will fail if this introduced name conflicts).\r\n\r\nMain usage would be for building complex LINQ queries which finally are displayed in a data grid so I want as many direct properties as possible instead of just nested object references."},"comment":{"url":"https://api.github.com/repos/dotnet/csharplang/issues/comments/391749061","html_url":"https://github.com/dotnet/csharplang/issues/1563#issuecomment-391749061","issue_url":"https://api.github.com/repos/dotnet/csharplang/issues/1563","id":391749061,"user":{"login":"springy76","id":16399318,"avatar_url":"https://avatars2.githubusercontent.com/u/16399318?v=4","gravatar_id":"","url":"https://api.github.com/users/springy76","html_url":"https://github.com/springy76","followers_url":"https://api.github.com/users/springy76/followers","following_url":"https://api.github.com/users/springy76/following{/other_user}","gists_url":"https://api.github.com/users/springy76/gists{/gist_id}","starred_url":"https://api.github.com/users/springy76/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/springy76/subscriptions","organizations_url":"https://api.github.com/users/springy76/orgs","repos_url":"https://api.github.com/users/springy76/repos","events_url":"https://api.github.com/users/springy76/events{/privacy}","received_events_url":"https://api.github.com/users/springy76/received_events","type":"User","site_admin":false},"created_at":"2018-05-24T15:06:11Z","updated_at":"2018-05-24T15:06:11Z","author_association":"NONE","body":"For me this is a every day issue way back to 2006 or so when LINQ appeared the first time, and on first day one of the first questions was \"where is select *\"?\r\n\r\nThe \"data grid control\" is actually LINQPad, both datagrid and HTML table view. There are days where I spend hours in prototyping queries or just studying data with all sorts of group-by etc.\r\nIn production code this is rare but occurs, too (but not \"grid\" related).\r\n\r\nWhat happens nearly every time is that I need a transition from IQueryable to IEnumerable to add additional columns which EF+SQL just cannot calculate:\r\n\r\n```\r\nfrom x in query.AsEnumerable()\r\nselect new {x.p1, x.p2, x.p3, x.p4, x.p5, x.p6, x.p7 [......], Bitmask = Convert.ToString(x.p27, 2)}\r\n```\r\ncould be so nice:\r\n```\r\nfrom x in query.AsEnumerable()\r\nselect new {x.*, Bitmask = Convert.ToString(x.p27, 2)}\r\n```\r\n\r\nSimilar thing with groupings because ALL THE TIME I'm forgetting to update the final select list when I modify the group key:\r\n\r\n```\r\nfrom x in enumerable\r\ngroup x by (x.p1, x.p2, x.p3) into g\r\nselect new { g.Key.*, Count = g.Count(), Samples = g.Take(3) }\r\n```\r\n\r\n"}}
{"actor":{"display_login":"springy76"}}