Uploaded image for project: 'iBatis for .NET'
  1. iBatis for .NET
  2. IBATISNET-265

generate for update is wrong

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • DataMapper 1.6.1
    • None
    • DataMapper
    • None
    • All environments

    Description

      When using ibatis to generate an update statement it ignores fields that is in the by field.

      example:
      Tablename
      Test
      Fields
      TestID
      est

      add parametermap

      use <generate table="Test" by="TestID"/>

      then execute an update

      Error is in:
      IBatisNet.DataMapper.Configuration.Statements.SqlGenerator.BuildUpdateQuery
      line
      210

      possible sollution:
      if (Array.BinarySearch(keysList, property.ColumnName) < 0)

      Attachments

        1. SqlGenerator.cs
          8 kB
          Ronald

        Activity

          People

            Unassigned Unassigned
            huuf Ronald
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:

              Time Tracking

                Estimated:
                Original Estimate - 0.25h
                0.25h
                Remaining:
                Remaining Estimate - 0.25h
                0.25h
                Logged:
                Time Spent - Not Specified
                Not Specified