Questions tagged [rowversion]

91 questions
0
votes
0 answers

Stored procedure implementation instead of hard coded queries In Postgres

Aurora Postgres 11.9 In SQL Server we strictly follow the good programming practice that "every single call land on DB from the application will be a stored procedure instead of simple queries". In Oracle, we haven't experienced the same thing may…
0
votes
0 answers

Migrate SQL Server database to Azure SQL Database preserving rowversion / timestamp

We need to migrate a database from SQL Server to an Azure SQL Database. In this database we do use rowversions (timestamp) extensively for synchronisation purposes with other systems. It is therefore important that these rowversions remain…
Chris
  • 323
  • 2
  • 12
0
votes
1 answer

how to convert ulong to rowversion

reference to converting sql server rowversion to long or ulong? i can convert SQL RowVersion to ulong by code: static ulong BigEndianToUInt64(byte[] bigEndianBinary) { return ((ulong)bigEndianBinary[0] << 56) | …
goldii
  • 242
  • 2
  • 18
0
votes
0 answers

Update a database record rowversion by not touching the record with SQL UPDATE?

I have two tables TableA and TabelB in SQL Server, there is a foreign key relationship between them, and TableA defined a rowversion column to synchronize things. It's required to update the rowversion of TableA if the corresponding record in TableB…
0
votes
1 answer

Rowversion field causes BULK INSERT to only import every other row

When I perform a BULK INSERT into a table with a rowversion field, only every other row gets imported. Here's my source text file: If I perform a BULK INSERT into a table with a rowversion field, only two rows are imported: However, if I do the…
mwolfe02
  • 23,787
  • 9
  • 91
  • 161
0
votes
2 answers

is rowversion a transactionally-consistent value to capture table data changes

If an ETL process attempts to detect data changes on system-versioned tables in SQL Server by including rows as defined by a rowversion column to be within a rowversion "delta window", e.g.: where row_version >= @previous_etl_cycle_rowversion and…
jjt
  • 125
  • 1
  • 10
0
votes
0 answers

Byte[] comparison in Linq enumerable

I'm trying to retrieve SQL records where the rowversion is greater than a certain value. In SQL this is trivial (WHERE RowVersion > x), however not so in Dynamic Linq queries. In my EF model I have applied the Timestamp annotation to the…
user3424480
  • 362
  • 2
  • 6
  • 19
0
votes
1 answer

MariaDB stores varbinary field with different value from the original field using PHP PDO

I'm using PHP - PDO to synchronize a SQL Server Table using RowVersion from our ERP to a MariaDB Database (hosting). When I save values in a local (office) MariaDB database version 5.5.56, everything goes fine and data is stored correctly. When I do…
Ramon
  • 94
  • 6
0
votes
0 answers

Entityframework ObjectContext Refresh changed Entities

i am looking for a way of refreshing Entities that changed in the Database. The Entities i want to refresh have a RowVersion [TimeStamp] Property. What i wanna do is refresh all my loaded Entities where the RowVersion in the database is greater…
user2130865
0
votes
0 answers

Audit history of sql child table

I'm recording all insert and update on TaskDetail table using a trigger,Now I want to assign multiple staff to a task, But if staff id stored in different child table how can I track audit history, I have considered storing staff id as comma…
Shijith
  • 3
  • 1
0
votes
0 answers

Using SQL Server rowversion instead to datetime to track changes

To fetch any record from table that are either inserted or updated, I am using created on date to get inserted records and updated on date to get rows in which any column is updated. Simple select query is: SELECT * FROM [Table] WITH…
0
votes
2 answers

SQL RowVersion incrementing before data has been augmented in Trigger

I've just started using T-SQL's RowVersion and I've noticed something very interesting. I created a Proc to update a table with a RowVersion column and at the end of this proc I print out a humanreadable date representation of RowVersion. I also…
user1501171
  • 210
  • 1
  • 3
  • 17
0
votes
1 answer

How to handle the Sql Version and C# byte array in Linq queries

We use entity framework to store our entities in the database. We use the repository pattern to wrap quite complicated Linq-queries. We want to unit test these queries against simple in memory collections. This is all fine and good until we ran into…
k.c.
  • 1,755
  • 1
  • 29
  • 53
0
votes
1 answer

OpenEdge Database Row Version

I am attempting to implement a row version strategy for tables in our OpenEdge database. The simple solution i have come up with would be to add an integer iRowVersion field to each table and have the write trigger validate and increment the field…
Andrew Stalker
  • 718
  • 5
  • 22
0
votes
1 answer

Delphi TClientDataset SQL Server RowVersion

Does anyone have any experience using SQL Server 's RowVersion column with TClientDataset? Specifically, I need to get the RowVersion value back on insert. It seems to get the RowVersion value back on updates but a newly inserted row it does not.
avidgoffer
  • 193
  • 1
  • 2
  • 18