1. Simple Explanation of primary key and rowid
Primary Key: The primary key is unique and not empty. It is used to identify a unique record.
Rowid: the actual physical address of the Data. You do not have to create a rowid yourself. You do not have the permission to create a rowid, which is an index generated by the Oracle system.
2. Can rowid be used as the primary key?
Yes. You can query the rowid field of any table during SELECT query.
3. When will rowid be used?
In my personal experience, since rowid can be used as a primary key, it can replace the Union primary key operation. After all, it is troublesome to use the Union primary key.
4. The rowid technique used in the actual program:
The front-end gridview displays the queried data, including querying, adding, deleting, and modifying database tables.
When querying data, you can also query the rowid field of the data. The rowid does not need to be displayed (as a hidden column), but can be hidden, especially when deleting or modifying data, you can directly use rowid. There are two advantages: one is that you can modify the value of the primary key, and the other is that modification and deletion are efficient and fast. Especially when a primary key is associated.