Sitelet https://github.com/rails-sqlserver/activerecord-sqlserver-adapter/issues/955
Skip to content

support stored procedures in SQLServerDatabaseTasks#structure_dump #955

Description

@jonahgeorge

Currently, SQLServerDatabaseTasks#structure_dump supports exporting tables and views; however, the underlying tool defncopy supports stored procedures as well. It would be particularly helpful to export stored procedures from an existing database, especially when activerecord-sqlserver-adapter already supports running them.

My current understanding is that SchemaStatements would need to be extended to return stored procedures (like tables and views on the underlying ActiveRecord connection). A query like the following may suffice:

SELECT distinct routine_schema, routine_name
FROM INFORMATION_SCHEMA.ROUTINES
WHERE ROUTINE_TYPE = 'PROCEDURE';

Related:

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions