Hi,
I'm currently developing a new application using ABP Commercial and MS SQL server database. The new application is based on a legacy application and needs to migrate all the data to the new application. My question is, during the data migration from an existing database, can I use the Guid column with newsequentialid() default value in table design?
- ABP Framework version: v5.2.0
- UI type: Angular
- DB provider: EF Core, MS SQL Server
- Tiered (MVC) or Identity Server Separated (Angular): yes - Identity Server
- Exception message and stack trace:
- Steps to reproduce the issue:"
3 Answer(s)
-
0
hi
never use Guid.NewGuid() to create Ids for your entities!
https://docs.abp.io/en/abp/latest/Guid-Generation
-
0
hi
never use Guid.NewGuid() to create Ids for your entities!
https://docs.abp.io/en/abp/latest/Guid-Generation
I'm using SQL server script for the data migration. The only option on the database level is newId() or newsequentialid(). Is there any problem if I use newsequentialid() for existing data?
-
0
We recommend that you use code(
IGuidGenerator
) to migrate.