Skip to content

Commit 327b102

Browse files
committed
Corrected the assembly, but this is still the old one. Microsoft.SqlServer.Server.SqlDataRecord should probably be used via some other reference package.
1 parent 3200cd5 commit 327b102

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/SqlClient.DesignTime/DesignTime.fs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -571,7 +571,7 @@ type DesignTime private() =
571571
//record.SetValues(values) |> ignore
572572

573573
//done via reflection because not implemented on Mono
574-
let sqlDataRecordType = typeof<System.Data.IDbCommand>.Assembly.GetType("Microsoft.SqlServer.Server.SqlDataRecord", throwOnError = true)
574+
let sqlDataRecordType = typeof<System.Data.SqlClient.SqlCommand>.Assembly.GetType("Microsoft.SqlServer.Server.SqlDataRecord", throwOnError = true)
575575
let record = Activator.CreateInstance(sqlDataRecordType, args = [| %%Expr.Coerce(Expr.NewArray(typeof<Microsoft.SqlServer.Server.SqlMetaData>, sqlMetas), typeof<obj>) |])
576576
sqlDataRecordType.GetMethod("SetValues").Invoke(record, [| values |]) |> ignore
577577

src/SqlClient/ISqlCommand.fs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -234,7 +234,7 @@ type ``ISqlCommand Implementation``(cfg: DesignTimeConfig, connection: Connectio
234234

235235
//done via reflection because not implemented on Mono
236236

237-
let sqlDataRecordType = typeof<IDbCommand>.Assembly.GetType("Microsoft.SqlServer.Server.SqlDataRecord", throwOnError = true)
237+
let sqlDataRecordType = typeof<System.Data.SqlClient.SqlCommand>.Assembly.GetType("Microsoft.SqlServer.Server.SqlDataRecord", throwOnError = true)
238238
let records = typeof<Linq.Enumerable>.GetMethod("Cast").MakeGenericMethod(sqlDataRecordType).Invoke(null, [| value |])
239239
let hasAny =
240240
let anyMeth =

0 commit comments

Comments
 (0)