Global Data Management Forum

Data Management Global

A hub for collaboration, learning, networking, and cultural exchange, and contributing to positive global engagement

 View Only

IBM.EntityFrameworkCore LINQ to SQL Trim() issues

  • 1.  IBM.EntityFrameworkCore LINQ to SQL Trim() issues

    Posted 06/22/22 09:10 AM
    Hi, I'm using driver
    "IBM.EntityFrameworkCore" Version="6.0.0.200" for LINQ to SQL queries in my C# project.

    All works fine except for the following:
    When running a LINQ to SQL query with Trim() like this:

    .Select(c => new { Code = c.accountcode.Trim(), Name = c.shortname.Trim() }).ToList()
    The result of the first trim is transferred to all subsequent Trim()'s. It's like the first result is being captured on the server in some sort of closure?

    Is this a Bug? if so where should I post it?

    My workaround is Select(x=>raw props).ToList().Select(x=>do trims here)

    Does anyone have a workaround that works on the server end? Or, is there a configuration option in the driver to trim all results somehow?

    Any help would be appreciated.


    ------------------------------
    Devron Blatchford
    ------------------------------

    #DataManagementGlobal
    #DataServerDrivers