Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Database & SysAdmin
  3. Database
  4. TSQL to print the content/inside of stored proc, definition of view and tables?

TSQL to print the content/inside of stored proc, definition of view and tables?

Scheduled Pinned Locked Moved Database
databasesql-serverxmlquestion
3 Posts 3 Posters 0 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • D Offline
    D Offline
    devvvy
    wrote on last edited by
    #1

    hello TSQL to print the content/inside of stored proc, definition of view and tables? The idea is to automate detection of any changes to stored proc or view/table schema. Thanks

    dev

    M G 2 Replies Last reply
    0
    • D devvvy

      hello TSQL to print the content/inside of stored proc, definition of view and tables? The idea is to automate detection of any changes to stored proc or view/table schema. Thanks

      dev

      M Offline
      M Offline
      Mycroft Holmes
      wrote on last edited by
      #2

      Uhm it's called source control and there are a vast number of systems built to meet this need. And they almost all cost money. Otherwise you can look into the system tables and possibly the schema views, all the procedure scripts are in there. You can write then out or copy them to another table where you could simply do a != comparison on the relevant fields.

      Never underestimate the power of human stupidity RAH

      1 Reply Last reply
      0
      • D devvvy

        hello TSQL to print the content/inside of stored proc, definition of view and tables? The idea is to automate detection of any changes to stored proc or view/table schema. Thanks

        dev

        G Offline
        G Offline
        Goutam Patra
        wrote on last edited by
        #3

        You may use 1. information_schema.columns for columns 2. information_schema.tables for tables 3. sp_helptext 'sp_procedurename' for SP Text

        1 Reply Last reply
        0
        Reply
        • Reply as topic
        Log in to reply
        • Oldest to Newest
        • Newest to Oldest
        • Most Votes


        • Login

        • Don't have an account? Register

        • Login or register to search.
        • First post
          Last post
        0
        • Categories
        • Recent
        • Tags
        • Popular
        • World
        • Users
        • Groups