Sybase to UDB conversion

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • AnandG

    Sybase to UDB conversion

    Hi,

    Could someone please advise on what is the equivalent of the following
    sybase trigger code to UDB.

    if @@test > 1
    begin
    return
    end

    TIA
    Andy G
  • Philip Nelson

    #2
    Re: Sybase to UDB conversion

    Andy,

    Maybe if you explain what the Sybase code means, us non-Sybase-literate
    folks can help you ?

    Thanks

    Phil

    On Tue, 13 Jan 2004 11:26:15 -0800, AnandG wrote:
    [color=blue]
    > Hi,
    >
    > Could someone please advise on what is the equivalent of the following
    > sybase trigger code to UDB.
    >
    > if @@test > 1
    > begin
    > return
    > end
    >
    > TIA
    > Andy G[/color]

    Comment

    • AnandG

      #3
      Re: Sybase to UDB conversion

      Actually, the @@test should be "@@nestleve l". We are having problem
      in converting triggers from sybase to udb. Many triggers depend on
      this variable. Following is the description of @@nestlevel in Sybase
      ASE SQL Reference

      @@nestlevel
      In Adaptive Server Enterprise, nesting level of current
      execution
      (initially 0). Each time a stored procedure or trigger calls
      another
      stored procedure or trigger, the nesting level is
      incremented.


      I would like to know is there any equivalent for this in UDB.

      Thanks

      agkrishnan74@ho tmail.com (AnandG) wrote in message news:<a7089fde. 0401131126.1048 c317@posting.go ogle.com>...[color=blue]
      > Hi,
      >
      > Could someone please advise on what is the equivalent of the following
      > sybase trigger code to UDB.
      >
      > if @@test > 1
      > begin
      > return
      > end
      >
      > TIA
      > Andy G[/color]

      Comment

      • Knut Stolze

        #4
        Re: Sybase to UDB conversion

        AnandG <agopalakrishna n@hotmail.com> wrote:
        [color=blue]
        > Actually, the @@test should be "@@nestleve l". We are having problem
        > in converting triggers from sybase to udb. Many triggers depend on
        > this variable. Following is the description of @@nestlevel in Sybase
        > ASE SQL Reference
        >
        > @@nestlevel
        > In Adaptive Server Enterprise, nesting level of current
        > execution
        > (initially 0). Each time a stored procedure or trigger calls
        > another
        > stored procedure or trigger, the nesting level is
        > incremented.
        >
        > I would like to know is there any equivalent for this in UDB.[/color]

        Stupid question maybe: what do you need the nesting level for? Wouldn't it
        be better to write your code in an independent fashion?

        --
        Knut Stolze
        Information Integration
        IBM Germany / University of Jena

        Comment

        • AnandG

          #5
          Re: Sybase to UDB conversion

          I agree, but there are more than 100 over triggers. I posted this due
          to the time constraint of the migration project. Changing the trigger
          logic is going to be lot of work, thought there might be someone who
          would have come across this...

          Knut Stolze <stolze@de.ibm. com> wrote in message news:<bu5vft$h8 f$1@fsuj29.rz.u ni-jena.de>...[color=blue]
          > AnandG <agopalakrishna n@hotmail.com> wrote:
          >[color=green]
          > > Actually, the @@test should be "@@nestleve l". We are having problem
          > > in converting triggers from sybase to udb. Many triggers depend on
          > > this variable. Following is the description of @@nestlevel in Sybase
          > > ASE SQL Reference
          > >
          > > @@nestlevel
          > > In Adaptive Server Enterprise, nesting level of current
          > > execution
          > > (initially 0). Each time a stored procedure or trigger calls
          > > another
          > > stored procedure or trigger, the nesting level is
          > > incremented.
          > >
          > > I would like to know is there any equivalent for this in UDB.[/color]
          >
          > Stupid question maybe: what do you need the nesting level for? Wouldn't it
          > be better to write your code in an independent fashion?[/color]

          Comment

          • Blair Adamache

            #6
            Re: Sybase to UDB conversion

            Have you tried the software migration toolkit? It might be able to
            automate some or all of the conversion:



            AnandG wrote:
            [color=blue]
            > I agree, but there are more than 100 over triggers. I posted this due
            > to the time constraint of the migration project. Changing the trigger
            > logic is going to be lot of work, thought there might be someone who
            > would have come across this...
            >
            > Knut Stolze <stolze@de.ibm. com> wrote in message news:<bu5vft$h8 f$1@fsuj29.rz.u ni-jena.de>...
            >[color=green]
            >>AnandG <agopalakrishna n@hotmail.com> wrote:
            >>
            >>[color=darkred]
            >>>Actually, the @@test should be "@@nestleve l". We are having problem
            >>>in converting triggers from sybase to udb. Many triggers depend on
            >>>this variable. Following is the description of @@nestlevel in Sybase
            >>>ASE SQL Reference
            >>>
            >>>@@nestleve l
            >>> In Adaptive Server Enterprise, nesting level of current
            >>>execution
            >>> (initially 0). Each time a stored procedure or trigger calls
            >>>another
            >>> stored procedure or trigger, the nesting level is
            >>>incremente d.
            >>>
            >>>I would like to know is there any equivalent for this in UDB.[/color]
            >>
            >>Stupid question maybe: what do you need the nesting level for? Wouldn't it
            >>be better to write your code in an independent fashion?[/color][/color]

            Comment

            • Mike

              #7
              Re: Sybase to UDB conversion

              agkrishnan74@ho tmail.com (AnandG) wrote in message news:<a7089fde. 0401131126.1048 c317@posting.go ogle.com>...[color=blue]
              > Hi,
              >
              > Could someone please advise on what is the equivalent of the following
              > sybase trigger code to UDB.
              >
              > if @@test > 1
              > begin
              > return
              > end
              >
              > TIA
              > Andy G[/color]

              I believe there is no direct equivalent for this construct.
              Instead, it may be wise to consider merging currently separate triggers.

              Comment

              • AnandG

                #8
                Re: Sybase to UDB conversion

                Blair,

                Yes, we are using the IBM migration tool kit. It doesn't recognize
                the @@nestlevel, it gives lot of error messages.

                Thanks
                _link98@yahoo.c om (Mike) wrote in message news:<be62324b. 0401161216.7da5 d0ee@posting.go ogle.com>...[color=blue]
                > agkrishnan74@ho tmail.com (AnandG) wrote in message news:<a7089fde. 0401131126.1048 c317@posting.go ogle.com>...[color=green]
                > > Hi,
                > >
                > > Could someone please advise on what is the equivalent of the following
                > > sybase trigger code to UDB.
                > >
                > > if @@test > 1
                > > begin
                > > return
                > > end
                > >
                > > TIA
                > > Andy G[/color]
                >
                > I believe there is no direct equivalent for this construct.
                > Instead, it may be wise to consider merging currently separate triggers.[/color]

                Comment

                Working...