Immediate-updating subcriptions

  • I have setup Transactional replication with "Immediate Updating Subscribers". Changes on publisher get replicated to the subscriber, without any errors. But when I try to UPDATE data at the subscriber I am getting the following error and not able to modify data at the subscriber:

    Server: Msg 137, Level 15, State 2, Line 5

    Must declare the variable '@c123o'.

    How can we correct this problem?

  • Do you get the same error on all tables, or just on one specific table? Immediate updating uses triggers to make the change to the publisher, probably there is an error in the trigger definition.

    Andy

  • Is you update being done thru stored procedure? I have not seen anything like this

    quote:


    Server: Msg 137, Level 15, State 2, Line 5

    Must declare the variable '@c123o'.


    except when a variable is used in code (usually stored procedures or written at the time). If not then it may be a procedure built only when Immediate-Updating is built and I jsut cannot find. Use profiler on the subscriber when things are slow and see if you can catch this in a trace to see where it may have come from or get the script to "Find a string in DB objects." at http://www.sqlservercentral.com/scripts/scriptdetails.asp?scriptid=184 and search Procedures, Triggers and Functions (last is SQL 2000) to find this varibale used.

    "Don't roll your eyes at me. I will tape them in place." (Teacher on Boston Public)

  • quote:


    Do you get the same error on all tables, or just on one specific table? Immediate updating uses triggers to make the change to the publisher, probably there is an error in the trigger definition.

    Andy


    I get this on all tables, even tried on nothwind. I feel it is somthing with the update trigger on subscriber table.

    Thanks,

    Louis

  • quote:


    Do you get the same error on all tables, or just on one specific table? Immediate updating uses triggers to make the change to the publisher, probably there is an error in the trigger definition.

    Andy


    Hello Andy,

    After further research I found that if I

    delete columns and reduce publishing table

    to 125 column (originally 141 columns) it works. With 126 columns I get error Server: Msg 137, Level 15, State 2, Line 5

    Must declare the variable '@c123o'.

    Does any one Know if there is max number of columns when replicating?

    Thanks,

    Lou

  • Not sure about max columns, I know there is a max row length with merge (around 6k) due to the overhead of the metadata.

    Andy

Viewing 6 posts - 1 through 5 (of 5 total)

You must be logged in to reply to this topic. Login to reply