Skip to content

Investigate warning regarding query splitting #75

@simon-wacker

Description

@simon-wacker

It occurs in various occasions. Here is one example:

Compiling a query which loads related collections for more than one collection navigation, either via 'Include' or through projection, but no 'QuerySplittingBehavior' has been configured. By default, Entity Framework will use 'QuerySplittingBehavior.SingleQuery', which can potentially result in slow query performance. See https://go.microsoft.com/fwlink/?linkid=2134277 for more information. To identify the query that's triggering this warning call 'ConfigureWarnings(w => w.Throw(RelationalEventId.MultipleCollectionIncludeWarning))'.

Executed DbCommand (75ms) [Parameters=[@__p_0='?' (DbType = Guid), @__p_1='?' (DbType = Int32)], CommandType='Text', CommandTimeout='30']
SELECT o4.c, o4."Id", o4."CoatedSide", o4."ColorRenderingIndices", o4."ComponentId", o4."CreatedAt", o4."CreatorId", o4."Description", o4."InfraredEmittances", o4."Locale", o4."Name", o4."NearnormalHemisphericalSolarReflectances", o4."NearnormalHemisphericalSolarTransmittances", o4."NearnormalHemisphericalVisibleReflectances", o4."NearnormalHemisphericalVisibleTransmittances", o4."Subtype", o4."Type", o4.xmin, o4."Warnings", o4."AppliedMethod_MethodId", o1."AppliedMethodOpticalDataId", o1."Id", o1."Name", o1."Value", o2."AppliedMethodOpticalDataId", o2."Id", o2."Name", o2."Value_DataId", o2."Value_DataKind", o2."Value_DataTimestamp", o2."Value_DatabaseId", o3."OpticalDataId", o3."Id", o3."ApproverId", o3."KeyFingerprint", o3."Query", o3."Response", o3."Signature", o3."Timestamp", o3."Publication_Abstract", o3."Publication_ArXiv", o3."Publication_Authors", o3."Publication_Doi", o3."Publication_Section", o3."Publication_Title", o3."Publication_Urn", o3."Publication_WebAddress", o3."Standard_Abstract", o3."Standard_Locator", o3."Standard_Section", o3."Standard_Standardizers", o3."Standard_Title", o3."Standard_Year", o3."Standard_Numeration_MainNumber", o3."Standard_Numeration_Prefix", o3."Standard_Numeration_Suffix", c."OpticalDataId", c."Id", c."AStar", c."BStar", c."LStar"
backend-1 | FROM (
backend-1 | SELECT (
backend-1 | SELECT count(*)::int
backend-1 | FROM database.optical_data AS o0
backend-1 | WHERE EXISTS (
backend-1 | SELECT 1
backend-1 | FROM database.get_https_resource AS g0
backend-1 | WHERE o0."Id" = g0."OpticalDataId" AND g0."DataFormatId" = @__p_0)) AS c, o."Id", o."CoatedSide", o."ColorRenderingIndices", o."ComponentId", o."CreatedAt", o."CreatorId", o."Description", o."InfraredEmittances", o."Locale", o."Name", o."NearnormalHemisphericalSolarReflectances", o."NearnormalHemisphericalSolarTransmittances", o."NearnormalHemisphericalVisibleReflectances", o."NearnormalHemisphericalVisibleTransmittances", o."Subtype", o."Type", o.xmin, o."Warnings", o."AppliedMethod_MethodId"
backend-1 | FROM database.optical_data AS o
backend-1 | WHERE EXISTS (
backend-1 | SELECT 1
backend-1 | FROM database.get_https_resource AS g
backend-1 | WHERE o."Id" = g."OpticalDataId" AND g."DataFormatId" = @__p_0)
backend-1 | ORDER BY o."Id"
backend-1 | LIMIT @__p_1
backend-1 | ) AS o4
backend-1 | LEFT JOIN database."optical_data_Arguments" AS o1 ON o4."Id" = o1."AppliedMethodOpticalDataId"
backend-1 | LEFT JOIN database."optical_data_Sources" AS o2 ON o4."Id" = o2."AppliedMethodOpticalDataId"
backend-1 | LEFT JOIN database."optical_data_Approvals" AS o3 ON o4."Id" = o3."OpticalDataId"
backend-1 | LEFT JOIN database."CielabColor" AS c ON o4."Id" = c."OpticalDataId"
backend-1 | ORDER BY o4."Id", o1."AppliedMethodOpticalDataId", o1."Id", o2."AppliedMethodOpticalDataId", o2."Id", o3."OpticalDataId", o3."Id", c."OpticalDataId"

Metadata

Metadata

Assignees

Labels

ISEFraunhofer Institute for Solar Energy Systems ISEenhancementNew feature or request

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions