Home > database > Consult everybody, partition table 1 billion line, the data do not how to operate?
Consult everybody, partition table 1 billion line, the data do not how to operate?
Time:10-10
The inside of the business is still there, but the data is not important, you can delete all, to rebuild table, how to operate better
CodePudding user response:
Table will be built inside the original partition table space, table structure index of these should be retained
CodePudding user response:
Partition information, alter table table_name truncate partition (p1) update the indexes; This isn't foolproof
CodePudding user response:
The plan is a lot of, probably a few: 1, modify the name of the table to rebuild, 2, delete the table again, 3, truncate directly, this time is bad to say, although all say this is very fast, but the actual operation, there is slow, 4, 2 #, according to a district truncate (if there is partition)