From b6699e1df6a00ad0b40d3694550a58c14668d088 Mon Sep 17 00:00:00 2001 From: Savorboard Date: Tue, 19 Nov 2019 16:01:28 +0800 Subject: [PATCH] Fix sql reader column index error --- src/DotNetCore.CAP.MySql/IDataStorage.MySql.cs | 6 +++--- src/DotNetCore.CAP.PostgreSql/IDataStorage.PostgreSql.cs | 6 +++--- src/DotNetCore.CAP.SqlServer/IDataStorage.SqlServer.cs | 6 +++--- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/src/DotNetCore.CAP.MySql/IDataStorage.MySql.cs b/src/DotNetCore.CAP.MySql/IDataStorage.MySql.cs index d4ba6da..7ce514f 100644 --- a/src/DotNetCore.CAP.MySql/IDataStorage.MySql.cs +++ b/src/DotNetCore.CAP.MySql/IDataStorage.MySql.cs @@ -195,9 +195,9 @@ namespace DotNetCore.CAP.MySql result.Add(new MediumMessage { DbId = reader.GetInt64(0).ToString(), - Origin = StringSerializer.DeSerialize(reader.GetString(3)), - Retries = reader.GetInt32(4), - Added = reader.GetDateTime(5) + Origin = StringSerializer.DeSerialize(reader.GetString(4)), + Retries = reader.GetInt32(5), + Added = reader.GetDateTime(6) }); } diff --git a/src/DotNetCore.CAP.PostgreSql/IDataStorage.PostgreSql.cs b/src/DotNetCore.CAP.PostgreSql/IDataStorage.PostgreSql.cs index d0cc568..b632498 100644 --- a/src/DotNetCore.CAP.PostgreSql/IDataStorage.PostgreSql.cs +++ b/src/DotNetCore.CAP.PostgreSql/IDataStorage.PostgreSql.cs @@ -203,9 +203,9 @@ namespace DotNetCore.CAP.PostgreSql result.Add(new MediumMessage { DbId = reader.GetInt64(0).ToString(), - Origin = StringSerializer.DeSerialize(reader.GetString(3)), - Retries = reader.GetInt32(4), - Added = reader.GetDateTime(5) + Origin = StringSerializer.DeSerialize(reader.GetString(4)), + Retries = reader.GetInt32(5), + Added = reader.GetDateTime(6) }); } diff --git a/src/DotNetCore.CAP.SqlServer/IDataStorage.SqlServer.cs b/src/DotNetCore.CAP.SqlServer/IDataStorage.SqlServer.cs index a665447..cdc9406 100644 --- a/src/DotNetCore.CAP.SqlServer/IDataStorage.SqlServer.cs +++ b/src/DotNetCore.CAP.SqlServer/IDataStorage.SqlServer.cs @@ -202,9 +202,9 @@ namespace DotNetCore.CAP.SqlServer result.Add(new MediumMessage { DbId = reader.GetInt64(0).ToString(), - Origin = StringSerializer.DeSerialize(reader.GetString(3)), - Retries = reader.GetInt32(4), - Added = reader.GetDateTime(5) + Origin = StringSerializer.DeSerialize(reader.GetString(4)), + Retries = reader.GetInt32(5), + Added = reader.GetDateTime(6) }); }