![]() We can overcome these issues in MySQL by using the functions given below. It can also cause performance issues because of the unordered values and their size.For example, we can imagine the expression WHERE id = '185e6dfd-1cc8-11eb-9a2c-107d1a24f935' instead of WHERE id = 5. It makes the debugging more difficult.If we store the UUID (16-bytes) values in the databases, it occupies more space/storage than integers (4-bytes) or big integers (8-bytes).Using UUID, we can generate the PRIMARY KEY value of the parent table and insert rows into both tables simultaneously.īesides the advantages, the following are the disadvantages of using UUID for a primary key: For example, if we want to insert data into parent and child tables, we must first insert data into the parent table, get generated id, and then fill record into the child table. It also simplifies replication (logic in the application).UUID values can be generated offline means we can generate it anywhere without exchanging information with the database server.UUID values do not provide information about our data, which means it is hard to guess.It allows us to merge rows from distributed/different databases across servers. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |