Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New pseudocolumn (RDB$RECORD_VERSION) to get number of the transaction that created a record version [CORE3291] #3659

Closed
firebird-automations opened this issue Dec 24, 2010 · 11 comments

Comments

@firebird-automations
Copy link
Collaborator

Submitted by: @aafemt

Votes: 2

It could be useful to know transaction number that created record version returned by query. Something like Oracle ora_rowscn pseudocolumn.

Commits: 22fef20

@firebird-automations
Copy link
Collaborator Author

Commented by: Nikolay Ponomarenko (pnv82)

Seem's it could be useful for custom replication engines

@firebird-automations
Copy link
Collaborator Author

Commented by: Sean Leyne (seanleyne)

Nikolay,

I was thinking the same thing, but given that the replication engine would have to check the Oldest Active Transaction value in order to use the version transaction number, I don't see what value the pseudocolumn would bring.

Further, given that there could be hundreds of versions for a record and that a connection can not set a specific transaction number there would be no way to perform a full sync.

@firebird-automations
Copy link
Collaborator Author

Commented by: @aafemt

For replication AFAIU this column is useless. I rather think about cumulative backup: select * from t where RDB$TRANSACTION_ID>2.
Internally the engine could use this column, for example, to control versioned metadata cache.

@firebird-automations
Copy link
Collaborator Author

Commented by: @dyemanov

If some record has been modified by the current transaction, this pseudo-column would return the current transaction ID rather than the ID of the transaction the committed record version belong to. Is it acceptable?

@firebird-automations
Copy link
Collaborator Author

Commented by: @aafemt

Of course it is. In this way the value is even more useful.

@firebird-automations
Copy link
Collaborator Author

Commented by: @hvlad

I'm not against this feature just want to add that it is impossible to create consistent view of database ("cumulative backup") using just this new pseudo-column.

@firebird-automations
Copy link
Collaborator Author

Modified by: @aafemt

description: It could be useful to know transaction number that created record version returned by query. => It could be useful to know transaction number that created record version returned by query. Something like Oracle ora_rowscn pseudocolumn.

@firebird-automations
Copy link
Collaborator Author

Modified by: @asfernandes

status: Open [ 1 ] => Resolved [ 5 ]

resolution: Fixed [ 1 ]

Fix Version: 3.0 Alpha 1 [ 10331 ]

assignee: Adriano dos Santos Fernandes [ asfernandes ]

@firebird-automations
Copy link
Collaborator Author

Modified by: @asfernandes

summary: New pseudocolumn to get number of transaction that created this record version => New pseudocolumn (RDB$RECORD_VERSION) to get number of the transaction that created a record version

@firebird-automations
Copy link
Collaborator Author

Modified by: @pavel-zotov

status: Resolved [ 5 ] => Resolved [ 5 ]

QA Status: Done successfully

@firebird-automations
Copy link
Collaborator Author

Modified by: @pavel-zotov

status: Resolved [ 5 ] => Closed [ 6 ]

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

No branches or pull requests

2 participants