Skip to content

vbnullstring as parameter causes error #9

@Energeer

Description

@Energeer

First of all thanks very much for this Library! Not sure if this is by design or if my usage is wrong, however if I pass a vbnullstring or "" as a parameter an error occurs.

The line below in AdoParameterProvider results in the size property of the ADO parameter defaulting to 0 for empty strings. The size property is not allowed to be 0 for string types (at least not in what I am using it for) and causes an error.

If IsCharMapping(Result.Type) And Len(Value) > 0 Then Result.Size = Len(Value)

I have fixed the issue in my project by changing the line to:

If IsCharMapping(Result.Type) Then
     If Len(Value) > 0 Then Result.Size = Len(Value) Else Result.Size = 1
End If

Is there a better way?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      pFad - Phonifier reborn

      Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

      Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


      Alternative Proxies:

      Alternative Proxy

      pFad Proxy

      pFad v3 Proxy

      pFad v4 Proxy