Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-35757

Add options to selectively dump procedures and functions in mysqldump

    XMLWordPrintable

Details

    • New Feature
    • Status: Open (View Workflow)
    • Minor
    • Resolution: Unresolved
    • None
    • None
    • None

    Description

      Description:
      Currently, mysqldump does not provide an option to dump specific procedures or functions. While we can dump selected tables, there's no equivalent functionality for routines. In environments with numerous stored procedures and functions, the ability to selectively dump routines would significantly ease migrations and backups.

      Benefits:

      • Easier migration of specific routines between environments
      • Reduced dump size and time when only certain routines are needed
      • Better control over what gets exported, enhancing security and reducing the risk of unintended data transfer

      This feature would significantly enhance the flexibility and usability of mysqldump, particularly for customers managing complex environments with numerous stored procedures and functions.

      Proposed solution
      Proposed New Options:
      --list-procedures: Dump only the specified list of procedures
      --list-functions: Dump only the specified list of functions

      Usage Examples:

      mysqldump --list-procedures=proc1,proc2,proc3 database_name mysqldump --list-functions=func1,func2,func3 database_name
      

      Considerations:

      • These new options should be mutually exclusive with the existing --routines option for safety and clarity.
      • If both --list-procedures and --list-functions are used, the dump should include the specified procedures and functions.
      • If a specified procedure or function doesn't exist, the tool should provide a warning but continue with the dump.

      Attachments

        Activity

          People

            Unassigned Unassigned
            vidyadhar.chelluru vidyadhar
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:

              Git Integration

                Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.