Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Replication problem with timestamp field

Status
Not open for further replies.

SiberianSnowBunny

Technical User
Joined
Jan 4, 2002
Messages
2
Location
GB
I am having problems setting up transactional replication for a SQL server 2000 database. Several of the tables have a timestamp column and after the initial snapshot has been created, the first new transactions to be posted fail with the following message 'cannot insert non-null values into a timestamp field'. According to Books online, the values in timestamp fields should not be replicated and a new value given by the subscriber to new rows. It seems though, that the sp_msins procedure is trying to insert a value into the timestamp field and is therefore failing. How do I define the articles/field/sp's in order that the all columns other than timestamp are replicated?
Any help would be much appreciated.
Simon
 
Simon - First off, I am not an expert on replication. But I use Merge replication in SQL Server 7.

I would think you would want all fields/cols to be replicated, evew dates.
You might want to check the data types in the from & to
tables to be sure the datetime fields are the same type.

Maybe someone else will be able to give more info.
John
 
Thanks for the response, John

I know that the table structure is identical between the two servers, as I created an auto-generated database script from the publisher. I have modified the script to tell the IDENTITY field it is 'not for replication' to prevent it from creating a new value when it is received at the subscriber, but there is no such feature (that I know of) for the TIMESTAMP datatype and it is one column that you cannot exclude from replication.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top