diff --git a/src/OpenTelemetry.Instrumentation.SqlClient/Implementation/SqlEventSourceListener.netfx.cs b/src/OpenTelemetry.Instrumentation.SqlClient/Implementation/SqlEventSourceListener.netfx.cs
index a06c77c428c..a2f950b1116 100644
--- a/src/OpenTelemetry.Instrumentation.SqlClient/Implementation/SqlEventSourceListener.netfx.cs
+++ b/src/OpenTelemetry.Instrumentation.SqlClient/Implementation/SqlEventSourceListener.netfx.cs
@@ -153,6 +153,15 @@ private void OnBeginExecute(EventWrittenEventArgs eventData)
activity.SetTag(SemanticConventions.AttributeDbStatement, commandText);
}
}
+
+ try
+ {
+ this.options.Enrich?.Invoke(activity, "OnCustom", eventData.Payload);
+ }
+ catch (Exception ex)
+ {
+ SqlClientInstrumentationEventSource.Log.EnrichmentException(ex);
+ }
}
private void OnEndExecute(EventWrittenEventArgs eventData)
diff --git a/src/OpenTelemetry.Instrumentation.SqlClient/SqlClientInstrumentationOptions.cs b/src/OpenTelemetry.Instrumentation.SqlClient/SqlClientInstrumentationOptions.cs
index fdb0e29eff4..eb2e66d0537 100644
--- a/src/OpenTelemetry.Instrumentation.SqlClient/SqlClientInstrumentationOptions.cs
+++ b/src/OpenTelemetry.Instrumentation.SqlClient/SqlClientInstrumentationOptions.cs
@@ -136,14 +136,14 @@ public class SqlClientInstrumentationOptions
/// raw SqlCommand object.
///
///
- /// Enrich is only executed on .NET and .NET Core
+ /// Enrich is only executed on .NET Framework and .NET
/// runtimes.
/// The parameters passed to the enrich action are:
///
/// - The being enriched.
/// - The name of the event. Currently only "OnCustom" is
/// used but more events may be added in the future.
- /// - The raw SqlCommand object from which additional
+ ///
- The raw SqlCommand object (.NET) or Event payload (.NET Framework) from which additional
/// information can be extracted to enrich the .
///