Table Partition Modification =P
Ok so i have an application where the user must beable to add partitions, modify partitions and delete partitions of a table.
There are many potential problems here and i need to work out exactly where i need to merge as opposed to drop, split as opposed to add etc..
I was thinking of ADDing partitons that are flagged to be added, Modifying partitions that are flagged to be modded and after all that DELeting the partitions that are flagged to be deleted, in that specific order so that data isn't lost in the scenario of a user dropping a high partition with its data, and then adding a new high partition. The data would be lost ofcourse, but would not be lost if the new high partition was added first because the old high part would be merged as opposed to dropped in that case
would this be the easiest safest way of doing things? is there a faster way? Thanks
I am a little lost here ^_^
I suppose that you could add a process to prevent partitions being dropped if they have any data in them, and require that a truncate be specifically issued by the user if data loss is required.
A user adding/splitting and dropping partitions? scary!
Pablo (Paul) Berzukov
Author of Understanding Database Administration
available at amazon and other bookstores.
Disclaimer: Advice is provided to the best of my knowledge but no implicit or explicit warranties are provided. Since the advisor explicitly encourages testing any and all suggestions on a test non-production environment advisor should not held liable or responsible for any actions taken based on the given advice.
Click Here to Expand Forum to Full Width