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. Trigger in SQL Server 2005

Trigger in SQL Server 2005

Scheduled Pinned Locked Moved Database
databasesql-serversysadminhelp
5 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.
  • R Offline
    R Offline
    rrrriiizz
    wrote on last edited by
    #1

    Hello all, I want to write simle trigger in sql server for auto generate numbers. Can any one help me regarding this. and also want to know the Basic Structure of triggers in sql server 2005.Please help me regarding this. Thanks Rizana

    J A 2 Replies Last reply
    0
    • R rrrriiizz

      Hello all, I want to write simle trigger in sql server for auto generate numbers. Can any one help me regarding this. and also want to know the Basic Structure of triggers in sql server 2005.Please help me regarding this. Thanks Rizana

      J Offline
      J Offline
      John_Adams
      wrote on last edited by
      #2

      Hi Rizana, The structure of Triggers in MS SQL SERVER 2005 is almost same as it was in MS SQL Server 2003 or 2000. However, for more details please go through the following links: http://blog.pijnenburg.it/?q=node/41[^] http://www.simple-talk.com/sql/sql-server-2005/sql-server-2005-ddl-trigger-workbench/[^] Hope this helps :).

      Regards, John Adams ComponentOne LLC

      R 1 Reply Last reply
      0
      • R rrrriiizz

        Hello all, I want to write simle trigger in sql server for auto generate numbers. Can any one help me regarding this. and also want to know the Basic Structure of triggers in sql server 2005.Please help me regarding this. Thanks Rizana

        A Offline
        A Offline
        Ashfield
        wrote on last edited by
        #3

        Firstly, you don't need a trigger to auto generate numbers, have an identity column instead. Secondly for the basic structure of a trigger try reading the help. In fact, in light of your question, I suggest you read up on triggers before attempting to use them as you seem unclear about what they are for.

        Bob Ashfield Consultants Ltd

        R 1 Reply Last reply
        0
        • J John_Adams

          Hi Rizana, The structure of Triggers in MS SQL SERVER 2005 is almost same as it was in MS SQL Server 2003 or 2000. However, for more details please go through the following links: http://blog.pijnenburg.it/?q=node/41[^] http://www.simple-talk.com/sql/sql-server-2005/sql-server-2005-ddl-trigger-workbench/[^] Hope this helps :).

          Regards, John Adams ComponentOne LLC

          R Offline
          R Offline
          rrrriiizz
          wrote on last edited by
          #4

          Thank You John

          1 Reply Last reply
          0
          • A Ashfield

            Firstly, you don't need a trigger to auto generate numbers, have an identity column instead. Secondly for the basic structure of a trigger try reading the help. In fact, in light of your question, I suggest you read up on triggers before attempting to use them as you seem unclear about what they are for.

            Bob Ashfield Consultants Ltd

            R Offline
            R Offline
            rrrriiizz
            wrote on last edited by
            #5

            Hello Mr.bob, i want to write trigger only, because i want to generate number with Preceeding alphabets like 'a001' 'b002' for taht only i need triggers usually in my graduation i wrote trigger in oracle 9 i. but i dont know with the sql server. any way thanks for your suggestion. can i get the above with out trigger Please let me Know. Thanks RRiiizzzz

            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