Hello,
I want to know how can we alter the size of the dafault autopk, there is something with custom autopk/pksequence, but I am unable to find How to make the autopk size - 3X of its default one?'
Thanks.
Komal
Solved! Go to Solution.
Views
Replies
Total Likes
Hi,
Autopk sequence goes by rdbms' capability and can be altered as needed, e.g. alter sequence ... maxvalue 99999.
Be mindful of the key's size, default autopk is 32 bit signed integer = ~2B max value.
Changing the field size by adding this attribute could work but sounds like something that would break warranty:
Thanks,
-Jon
Hi,
Autopk sequence goes by rdbms' capability and can be altered as needed, e.g. alter sequence ... maxvalue 99999.
Be mindful of the key's size, default autopk is 32 bit signed integer = ~2B max value.
Changing the field size by adding this attribute could work but sounds like something that would break warranty:
Thanks,
-Jon
Hi Jon,
After gathering a lot of information, I think we can use pksequence to alter the default size of autopk which we mention in the main element of the schema body.
By default autopk takes 32 bit size and enrolled its pksequence under "XtkNewId" by default, yes, we don't mention this.
Now let's say I wanted to make its size of 64 bit, now I want to know under which schema(instead of XtkNewId) we can store this updated default size of autopk?
I referred: Database mapping | Adobe Campaign
A snippet from Database mapping | Adobe Campaign
A sequence referenced in an Adobe Campaign schema (NmsTrackingLogId for example) must be associated to a SQL function that returns the number of IDs in the parameters, separated by commas. This function must be called GetNewXXXIds, where XXX is the name of the sequence (GetNewNmsTrackingLogIds for example). View the postgres-nms.sql, mssql-nms.sql or oracle-nms.sql files provided with the appliation in the datakit/nms/eng/sql/ directory to recover the example of a ‘NmsTrackingLogId’ sequence creation for each database engine.
Also, as per my knowledge we can't exceed the size of 64 bit using pksequence for autopk, please reflect your knowledge on this point as well.
Thanks.
Komal
Views
Replies
Total Likes
Views
Replies
Total Likes
Hey,
Thank you. I think that might help.
Komal
Views
Replies
Total Likes