- 2026-05-29 1.1.18 Corrección rutina LeeMysql y LeeMysqlBytArray para que como maximo se admitan 2048 caracteres string
This commit is contained in:
17
bbdd.vb
17
bbdd.vb
@@ -4,6 +4,7 @@ Imports System.Data.Common
|
||||
Imports System.Data.SqlClient
|
||||
Imports System.Globalization
|
||||
Imports System.IO
|
||||
Imports tsUtilidades.Extensiones
|
||||
Public Class bbdd
|
||||
Public Shared Function EjeMySqlHex(BD As DbConnection, sqlh As String) As String
|
||||
Try
|
||||
@@ -85,7 +86,7 @@ Public Class bbdd
|
||||
Tipo = "N"
|
||||
Tamaño = 20
|
||||
End Select
|
||||
If Tamaño <= 1024 Then
|
||||
If Tamaño <= 2048 Then
|
||||
sLinea &= dc.ColumnName & "(" & Tipo & iInicioBuffer.ToString & ";" & Tamaño.ToString & ")|"
|
||||
iInicioBuffer += Tamaño
|
||||
End If
|
||||
@@ -96,10 +97,11 @@ Public Class bbdd
|
||||
For Each dc In dt.Columns
|
||||
Select Case dc.DataType
|
||||
Case GetType(String)
|
||||
Dim tam = System.Math.Min(2048, dc.MaxLength)
|
||||
If Not dr(dc) Is DBNull.Value Then
|
||||
sLinea &= dr(dc).ToString.PadRight(dc.MaxLength, " ")
|
||||
sLinea &= dr(dc).ToString.Acortar(tam).PadRight(tam, " ")
|
||||
Else
|
||||
sLinea &= "".PadRight(System.Math.Min(2048, dc.MaxLength), " ")
|
||||
sLinea &= "".PadRight(tam, " ")
|
||||
End If
|
||||
Case GetType(DateTime), GetType(Date)
|
||||
Dim sFecha As String = "null"
|
||||
@@ -151,7 +153,7 @@ Public Class bbdd
|
||||
Select Case dc.DataType
|
||||
Case GetType(String)
|
||||
Tipo = "X"
|
||||
Tamaño = dc.MaxLength
|
||||
Tamaño = System.Math.Min(2048, dc.MaxLength)
|
||||
Case GetType(DateTime), GetType(Date)
|
||||
Tipo = "F"
|
||||
Tamaño = 20
|
||||
@@ -159,7 +161,7 @@ Public Class bbdd
|
||||
Tipo = "N"
|
||||
Tamaño = 20
|
||||
End Select
|
||||
If Tamaño <= 1024 Then
|
||||
If Tamaño <= 2048 Then
|
||||
sLinea &= dc.ColumnName & "(" & Tipo & iInicioBuffer.ToString & ";" & Tamaño.ToString & ")|"
|
||||
iInicioBuffer += Tamaño
|
||||
End If
|
||||
@@ -170,10 +172,11 @@ Public Class bbdd
|
||||
For Each dc In dt.Columns
|
||||
Select Case dc.DataType
|
||||
Case GetType(String)
|
||||
Dim tam = System.Math.Min(2048, dc.MaxLength)
|
||||
If Not dr(dc) Is DBNull.Value Then
|
||||
sLinea &= dr(dc).ToString.PadRight(dc.MaxLength, " ")
|
||||
sLinea &= dr(dc).ToString.Acortar(tam).PadRight(tam, " ")
|
||||
Else
|
||||
sLinea &= "".PadRight(dc.MaxLength, " ")
|
||||
sLinea &= "".PadRight(tam, " ")
|
||||
End If
|
||||
Case GetType(DateTime), GetType(Date)
|
||||
Dim sFecha As String = "null"
|
||||
|
||||
@@ -16,11 +16,12 @@
|
||||
<TargetFramework>net8.0</TargetFramework>
|
||||
<PackageId>tsUtilidades</PackageId>
|
||||
<PackageTags>net8.0, libreria</PackageTags>
|
||||
<Version>1.1.17</Version>
|
||||
<Version>1.1.18</Version>
|
||||
<Authors>Manuel</Authors>
|
||||
<Company>Tecnosis S.A</Company>
|
||||
<Description>Utilidades Varias</Description>
|
||||
<PackageReleaseNotes>
|
||||
- 2026-05-29 1.1.18 Corrección rutina LeeMysql y LeeMysqlBytArray para que como maximo se admitan 2048 caracteres string
|
||||
- 2026-05-29 1.1.17 Corrección rutina LeeMysql para que como maximo se admitan 2048 caracteres string
|
||||
- 2026-05-19 1.1.16 Corrección multiplataforma tsNotificacionesClient
|
||||
- 2026-05-12 1.1.15 Se corrige tsNotificacionesClient
|
||||
|
||||
Reference in New Issue
Block a user