Skip to content

Is version column in Sql Server supposed to be populated after an update? #700

Open

Description

@preiius

I have a column like in your example:

    [VersionColumn("Version", VersionColumnType.RowVersion)]
    public byte[] Version { get; set; }

After an update, I have to read poco to get new version, otherwise I get 'System.Data.DBConcurrencyException' exception on subsequent update.

Correct me if I'm wrong, according to following line, are you updating version property after update but for VersionColumnType.Number only?

if (!string.IsNullOrEmpty(preparedStatement.VersionName) && preparedStatement.VersionColumnType == VersionColumnType.Number)

Activity

  1. schotime commented on Nov 19, 2024

    @schotime
    Owner

    Thats correct. Happy to take PRs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions