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. Have you seen a sql tool? [modified]

Have you seen a sql tool? [modified]

Scheduled Pinned Locked Moved Database
databasequestionannouncement
15 Posts 7 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.
  • T Offline
    T Offline
    Tomz_KV
    wrote on last edited by
    #1

    Have you seen a sql tool that can generate stored procedures against a table for select, insert, update and delete? Sql2008 provides scripts for the four actions. But the code is far from a stored procedure. Thanks,

    TOMZ_KV

    moved on Friday, February 18, 2011 4:26 PM

    H B E S P 6 Replies Last reply
    0
    • T Tomz_KV

      Have you seen a sql tool that can generate stored procedures against a table for select, insert, update and delete? Sql2008 provides scripts for the four actions. But the code is far from a stored procedure. Thanks,

      TOMZ_KV

      moved on Friday, February 18, 2011 4:26 PM

      H Offline
      H Offline
      Henry Minute
      wrote on last edited by
      #2

      Try SSMS ToolsPack[^]. I like it a lot.

      Henry Minute Do not read medical books! You could die of a misprint. - Mark Twain Girl: (staring) "Why do you need an icy cucumber?" “I want to report a fraud. The government is lying to us all.” I wouldn't let CG touch my Abacus! When you're wrestling a gorilla, you don't stop when you're tired, you stop when the gorilla is.

      T B 3 Replies Last reply
      0
      • T Tomz_KV

        Have you seen a sql tool that can generate stored procedures against a table for select, insert, update and delete? Sql2008 provides scripts for the four actions. But the code is far from a stored procedure. Thanks,

        TOMZ_KV

        moved on Friday, February 18, 2011 4:26 PM

        B Offline
        B Offline
        Brady Kelly
        wrote on last edited by
        #3

        The RedGate tools could probably help you, and if it's an immediate problem, you can use their evaluation period.

        T 1 Reply Last reply
        0
        • H Henry Minute

          Try SSMS ToolsPack[^]. I like it a lot.

          Henry Minute Do not read medical books! You could die of a misprint. - Mark Twain Girl: (staring) "Why do you need an icy cucumber?" “I want to report a fraud. The government is lying to us all.” I wouldn't let CG touch my Abacus! When you're wrestling a gorilla, you don't stop when you're tired, you stop when the gorilla is.

          B Offline
          B Offline
          Brady Kelly
          wrote on last edited by
          #4

          Wow, thanks! :) And I thought RedGate had some evil monopoly on SSMS add-ons. It looked possible to do when I checked it out years ago, but insanely undocumented. I know it's the VS shell, but there isn't an explicit, public SSMS extension interface.

          H 1 Reply Last reply
          0
          • H Henry Minute

            Try SSMS ToolsPack[^]. I like it a lot.

            Henry Minute Do not read medical books! You could die of a misprint. - Mark Twain Girl: (staring) "Why do you need an icy cucumber?" “I want to report a fraud. The government is lying to us all.” I wouldn't let CG touch my Abacus! When you're wrestling a gorilla, you don't stop when you're tired, you stop when the gorilla is.

            T Offline
            T Offline
            Tomz_KV
            wrote on last edited by
            #5

            I'll take a look. thanks,

            TOMZ_KV

            1 Reply Last reply
            0
            • B Brady Kelly

              The RedGate tools could probably help you, and if it's an immediate problem, you can use their evaluation period.

              T Offline
              T Offline
              Tomz_KV
              wrote on last edited by
              #6

              Thanks for the info.

              TOMZ_KV

              1 Reply Last reply
              0
              • B Brady Kelly

                Wow, thanks! :) And I thought RedGate had some evil monopoly on SSMS add-ons. It looked possible to do when I checked it out years ago, but insanely undocumented. I know it's the VS shell, but there isn't an explicit, public SSMS extension interface.

                H Offline
                H Offline
                Henry Minute
                wrote on last edited by
                #7

                Brady Kelly wrote:

                but insanely undocumented.

                Oh yusssss! The guy that wrote it does a lot of good stuff.

                Henry Minute Do not read medical books! You could die of a misprint. - Mark Twain Girl: (staring) "Why do you need an icy cucumber?" “I want to report a fraud. The government is lying to us all.” I wouldn't let CG touch my Abacus! When you're wrestling a gorilla, you don't stop when you're tired, you stop when the gorilla is.

                1 Reply Last reply
                0
                • H Henry Minute

                  Try SSMS ToolsPack[^]. I like it a lot.

                  Henry Minute Do not read medical books! You could die of a misprint. - Mark Twain Girl: (staring) "Why do you need an icy cucumber?" “I want to report a fraud. The government is lying to us all.” I wouldn't let CG touch my Abacus! When you're wrestling a gorilla, you don't stop when you're tired, you stop when the gorilla is.

                  T Offline
                  T Offline
                  Tomz_KV
                  wrote on last edited by
                  #8

                  I just installed it and tried. It is a great tool. Thanks again.

                  TOMZ_KV

                  H 1 Reply Last reply
                  0
                  • T Tomz_KV

                    I just installed it and tried. It is a great tool. Thanks again.

                    TOMZ_KV

                    H Offline
                    H Offline
                    Henry Minute
                    wrote on last edited by
                    #9

                    It's a pleasure

                    Henry Minute Do not read medical books! You could die of a misprint. - Mark Twain Girl: (staring) "Why do you need an icy cucumber?" “I want to report a fraud. The government is lying to us all.” I wouldn't let CG touch my Abacus! When you're wrestling a gorilla, you don't stop when you're tired, you stop when the gorilla is.

                    1 Reply Last reply
                    0
                    • T Tomz_KV

                      Have you seen a sql tool that can generate stored procedures against a table for select, insert, update and delete? Sql2008 provides scripts for the four actions. But the code is far from a stored procedure. Thanks,

                      TOMZ_KV

                      moved on Friday, February 18, 2011 4:26 PM

                      E Offline
                      E Offline
                      Ennis Ray Lynch Jr
                      wrote on last edited by
                      #10

                      I use the script below to create auto gen scripts for crud. Mix and match to suit your needs. Once you have what you want save it as an sp with the table name as a parameter and you are good to go.

                      SELECT * FROM sysColumns WHERE id = (select id from sysObjects where name = 'myTable');

                      Need custom software developed? I do custom programming based primarily on MS tools with an emphasis on C# development and consulting. I also do Android Programming as I find it a refreshing break from the MS. "And they, since they Were not the one dead, turned to their affairs" -- Robert Frost

                      T 1 Reply Last reply
                      0
                      • T Tomz_KV

                        Have you seen a sql tool that can generate stored procedures against a table for select, insert, update and delete? Sql2008 provides scripts for the four actions. But the code is far from a stored procedure. Thanks,

                        TOMZ_KV

                        moved on Friday, February 18, 2011 4:26 PM

                        S Offline
                        S Offline
                        Steve Wellens
                        wrote on last edited by
                        #11

                        You can also do it with Visual Studio. http://weblogs.asp.net/stevewellens/archive/2009/12/11/automatically-generate-stored-procedures-with-visual-studio.aspx[^]

                        Steve Wellens

                        T 1 Reply Last reply
                        0
                        • E Ennis Ray Lynch Jr

                          I use the script below to create auto gen scripts for crud. Mix and match to suit your needs. Once you have what you want save it as an sp with the table name as a parameter and you are good to go.

                          SELECT * FROM sysColumns WHERE id = (select id from sysObjects where name = 'myTable');

                          Need custom software developed? I do custom programming based primarily on MS tools with an emphasis on C# development and consulting. I also do Android Programming as I find it a refreshing break from the MS. "And they, since they Were not the one dead, turned to their affairs" -- Robert Frost

                          T Offline
                          T Offline
                          Tomz_KV
                          wrote on last edited by
                          #12

                          Thanks for your help!

                          TOMZ_KV

                          1 Reply Last reply
                          0
                          • S Steve Wellens

                            You can also do it with Visual Studio. http://weblogs.asp.net/stevewellens/archive/2009/12/11/automatically-generate-stored-procedures-with-visual-studio.aspx[^]

                            Steve Wellens

                            T Offline
                            T Offline
                            Tomz_KV
                            wrote on last edited by
                            #13

                            A great trick. Wish sql server have this functionality natively. Thanks,

                            TOMZ_KV

                            1 Reply Last reply
                            0
                            • T Tomz_KV

                              Have you seen a sql tool that can generate stored procedures against a table for select, insert, update and delete? Sql2008 provides scripts for the four actions. But the code is far from a stored procedure. Thanks,

                              TOMZ_KV

                              moved on Friday, February 18, 2011 4:26 PM

                              P Offline
                              P Offline
                              PIEBALDconsult
                              wrote on last edited by
                              #14

                              I'm glad you got answers you like. But... Personally I don't see the point in writing stored procedures that simply do those tasks -- especially update; update what? -- database tasks depend on the needs of business requirements which often don't include simple inserts, updates, and deletes on individual tables. Most database tables don't exist all on their own and several operations need to be executed at one time. It's well known that I don't like stored procedures at all, but at least they should be written to perform a higher-level operation than one simple operation.

                              1 Reply Last reply
                              0
                              • T Tomz_KV

                                Have you seen a sql tool that can generate stored procedures against a table for select, insert, update and delete? Sql2008 provides scripts for the four actions. But the code is far from a stored procedure. Thanks,

                                TOMZ_KV

                                moved on Friday, February 18, 2011 4:26 PM

                                F Offline
                                F Offline
                                fjdiewornncalwe
                                wrote on last edited by
                                #15

                                I've seen lots of tools make attempts at using sql, but in response to your question all you have to do is wrap the generated sql in a create procedure call, add parameters and voila, you have your skeleton procedure. Of course I believe that all procedures should do whatever they can to protect the data so I insist that any procedures written on my watch contain validation of whatever can be validated.

                                I wasn't, now I am, then I won't be anymore.

                                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