Events
Mar 17, 11 PM - Mar 21, 11 PM
Join the meetup series to build scalable AI solutions based on real-world use cases with fellow developers and experts.
Register nowThis browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
Converts a collection of collections into a flattened collection. The new collection contains all the same elements as the old collection, but without a nested structure.
FLATTEN ( collection )
collection
Any valid expression that returns a collection of value collections to flatten into a single collection.
FLATTEN
is one of the Entity SQL set operators. All Entity SQL set operators are evaluated from left to right. See EXCEPT for precedence information for the Entity SQL set operators.
The following Entity SQL query uses the FLATTEN
operator to convert a collection of collections into a flattened collection. To compile and run this query, follow these steps:
Follow the procedure in How to: Execute a Query that Returns StructuralType Results.
Pass the following query as an argument to the ExecuteStructuralTypeQuery
method:
FLATTEN(SELECT VALUE c.SalesOrderHeaders From
AdventureWorksEntities.Contacts AS c)
Events
Mar 17, 11 PM - Mar 21, 11 PM
Join the meetup series to build scalable AI solutions based on real-world use cases with fellow developers and experts.
Register now