Replies: 2 comments 4 replies
-
I don’t see how it could happen 🤔 could you provide a reproducer? BTW UUID can be generated client-side, which avoids declaring your identifier nullable, which is better. |
Beta Was this translation helpful? Give feedback.
1 reply
-
The work-around is to not use the auto-generation in the entity: #[ORM\Id]
#[ORM\Column(type: UuidType::NAME, unique: true)]
private ?Uuid $id = null;
public function __construct()
{
$this->id = Uuid::v7();
} It works fine with no problems. |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
My UUID config is as follows:
./bin/console debug:config framework uid
outputs:My entity has:
The auto-generated entity ID UUIDs are V6, not V7.
If I inspect any of the UUID primary keys in the database with:
./bin/console uuid:inspect 1eea7e0f-d006-64a2-9024-6b5706aaf847
It outputs:
Question
How does one configure the Doctrine Bridge UUID generator to generate V7 UUIDs?
Beta Was this translation helpful? Give feedback.
All reactions