on 2015 Aug 06 6:00 AM
I'm using the output of DBUNLOAD to compare databases before and after migrations, including the unloaded data. That usually works fine.
However, now and then, the diff tool displays differences for some tables, and that seems to be due to the fact that these tables have (non-unique) clustered indexes that do not build the primary key - and therefore may order data non-deterministically. Well, that's documented behaviour:
ORDER clause With ORDER ON (the default), the exported data is ordered by clustered index if one exists. If a clustered index does not exist, the exported data is ordered by primary key values.
I do understand that this default order makes sense particularly to speed up the reload. And of course I can do separat "UNLOAD SELECT * FROM myTABLE ORDER BY MyPk" statements to unload data in the desired order.
However, if would be nice if DBUNLOAD would have an option (say, "-up") to always use primary key (or at least an unique clustered key) to order the output.
To add: Since DBUNLOAD certainly makes use of the UNLOAD TABLE/MATERIALIZED VIEW statement, the suggested enhancement would apply to that, as well.
Request clarification before answering.
Your suggestion is noted. However we would not be able to use the -up switch for dbunload since this switch is already defined to mean "unload passwords" in v17. We'll pick something else (perhaps -uk for "unload by [primary] key"?)
I've added this to our future enhancements list.
Thanks for the suggestion.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
75 | |
30 | |
9 | |
7 | |
7 | |
6 | |
6 | |
5 | |
5 | |
5 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.