Skip to content
Advertisement

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:

Now, I am faced with a problem, how to convert ulong to byte [8]? I save the value of rowversion to a file, then read it and use it to make the query. the query parameter should be byte[] , not ulong . otherwise , there is an error will be raised.

Advertisement

Answer

i got an answer from BigEndian.GetBytes Method (Int64)

thanks all.

User contributions licensed under: CC BY-SA
2 People found this is helpful
Advertisement