We announce the release of Mags Pro with lots of features. View beautifuldemos

Drop/change the primary key of a table

This topic contains 1 reply, has 2 voices, and was last updated by  Theme Horse Support Team 10 months, 1 week ago.

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
  • #58749


    I need to change the primary key of a table. Is this possible to do in a migration? If not, what is the best way to recreate the table and copy the rows in a migration?

    Here is the original schema:

    $this->table_prefix . ‘flair_triggers’ => array(
    ‘COLUMNS’ => array(
    ‘flair_id’ => array(‘UINT’, 0),
    ‘trig_name’ => array(‘VCHAR’, ”),
    ‘trig_value’ => array(‘UINT’, 0),
    ‘PRIMARY_KEY’ => array(‘flair_id’, ‘trig_value’),



    Sorry! We only provide the support for our themes.
    As of your request you need a professional who knows all database stuff.

    Thank you!

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic.