Darshan Mehta
Darshan Mehta

Reputation: 30809

Sybase ASE : Table partitioning

I am working on partitioning a huge table in Sybase. The use case is, the table has grown over the years and the applications do not need data beyond let's say 6 months. So, I need to archive some of the rows. I am exploring the following approach:

Now, in order for me to do this, I need to partition the existing table and have a couple of questions (I am not a Sybase or a DB expert):

Upvotes: 0

Views: 1605

Answers (1)

user1230977
user1230977

Reputation: 1

Partitioning is meant to:

  1. Reduce time in maintenance tasks (dbcc, update statistics, and so on)
  2. Savings in disk usage (i.e. use slow disks for cold data)
  3. Achieve performance gains (with important previous considerations)

If you are in cases 1 or 2 the answer is:

To create a range partition you don't need to set an upper value; the upper value for the range is implicitly defined when you create the next partition. The next partition can be defined at any time by means of alter table

If you are in case 3:

Be very careful defining the partition columns; ideally they must match the where clause of your queries. Use a meaningful global index, so that ASE is able to find the location of the rows in every partition. Use local indexes for the rest.

Upvotes: 0

Related Questions