Stanislav Lukyanov created IGNITE-25081:
-------------------------------------------

             Summary: Add virtual fields __key, __val, __record, __timestamp
                 Key: IGNITE-25081
                 URL: https://issues.apache.org/jira/browse/IGNITE-25081
             Project: Ignite
          Issue Type: Improvement
          Components: sql
            Reporter: Stanislav Lukyanov


Add virtual fields to extract row's components and metadata.
 * __key returns the PK; if PK is single-column, __key has the column type; 
otherwise, it's a VARBINARY with the BinaryTuple of the PK.
 * __val returns the value; if the val is single-column, __val has the column 
type; otherwise, it's a VARBINARY with the BinaryTuple of the value.
 * __record returns the full record as a BinaryTuple; it's always VARBINARY.
 * __hybridtimestamp is a BIGINT with the record's hybrid timestamp
 ** The time is a little long but __timestamp will likely be confused with an 
actual time, e.g. TIMESTAMP, which it isn't.

These values are generally useful; __key and __val were often used for various 
purposes in AI2, and __record is similar. __hybridtimestamp is useful for 
diagnostics, e.g. to check that the entry has the same timestamp on different 
replicas.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to