Sybase NNTP forums - End Of Life (EOL)

The NNTP forums from Sybase - forums.sybase.com - are now closed.

All new questions should be directed to the appropriate forum at the SAP Community Network (SCN).

Individual products have links to the respective forums on SCN, or you can go to SCN and search for your product in the search box (upper right corner) to find your specific developer center.

Cannot Update Primary Key Value with dbremote.exe

2 posts in replicator Last posting was on 2005-12-15 05:36:39.0Z
bienkowm Posted on 2005-12-14 16:41:48.0Z
Sender: 1fb5.43a04a0d.1804289383@sybase.com
From: bienkowm
Newsgroups: sybase.public.ase.replicator
Subject: Cannot Update Primary Key Value with dbremote.exe
X-Mailer: WebNews to Mail Gateway v1.1t
Message-ID: <43a04b4c.1fc8.1681692777@sybase.com>
MIME-Version: 1.0
Content-Type: multipart/mixed; boundary="-=_forums-1-dub43a04b4c"
NNTP-Posting-Host: 10.22.241.41
X-Original-NNTP-Posting-Host: 10.22.241.41
Date: 14 Dec 2005 08:41:48 -0800
X-Trace: forums-1-dub 1134578508 10.22.241.41 (14 Dec 2005 08:41:48 -0800)
X-Original-Trace: 14 Dec 2005 08:41:48 -0800, 10.22.241.41
Lines: 3037
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub sybase.public.ase.replicator:120
Article PK: 103356

Please help me !!!


I have ASE 9.0.2.3221 version and use to I have ASE 7.0.
After upgrade database to the latest version I have a huge
problem w dbremote replication. I found a post at forum
site
its very similar problem

“Cannot update primary key for table”


http://groups.google.pl/group/sybase.public.sqlanywhere.mobilink/browse_thread/thread/5bafa6c83e7a9fcd/536954ae19637d0f?lnk=st&q="SQL+statement+failed:+(-780)+Cannot+update+primary+key+for+table"&rnum=2&hl=pl#536954ae19637d0f

This is my problem !!!!

Piece of replication log (name of file - look below
“Agent dbremote.exe setting(dbremote)”)):


I. 12/14 16:31:19. UPDATE DBA.zl
SET id_st_z='A',
id_kom='WA051214163001019802',
czas='16:30:01.715 2005/12/14',
id_work='tester'
VERIFY (czas, id_work)
VALUES (NULL,NULL) WHERE
cur_data='2005/12/14' AND
department='22222249' AND nr='49'
AND nrzlec=55555555
AND id_st_z ='R' AND
id_w_z='W'

SQL statement failed: (-780) Cannot update primary key for
table 'zl' involved in a publication
E. 12/14 16:31:20. Skipping:
E. 12/14 16:31:20. UPDATE DBA.zl

id_st_z – is a primary key and as I sad I cannot change
it. How can I resolve that problem ???

I CANNOT INTERFERE IN STRUCTURE AND DATA IN DATABASE BECAUSE
IM NOT A DESIGNER.





ASE and remote database configuration details

ASE Version:

9.0.2.3221


Agent dbremote.exe setting(dbremote)

-c "uid=db_remote;pwd=xxxxxxxx;eng= testPRDOZ
" -t -v -o C:\replication.log

Remote dbsrv9.exe database setting

-n testPRDOZ
-c 16M
-gm 20
-gf
-x tcpip
"E:\Baza\test\PRD\testPRD.db"

Database options:



'DBA','Date_order','YMD'
'DBA','ISQL_command_timing','On'
'DBA','ISQL_plan','Graphical'
'DBA','On_error','Prompt'
'DBA','Prevent_article_pkey_update','OFF'
'PUBLIC','Allow_nulls_by_default','On'
'PUBLIC','Allow_replication_pkey_update','On'
'PUBLIC','Allow_sync_pkey_update','On'
'PUBLIC','Ansi_blanks','Off'
'PUBLIC','Ansi_close_cursors_on_rollback','Off'
'PUBLIC','Ansi_integer_overflow','Off'
'PUBLIC','Ansi_permissions','On'
'PUBLIC','Ansi_update_constraints','Off'
'PUBLIC','Ansinull','On'
'PUBLIC','Assume_distinct_servers','Off'
'PUBLIC','Auditing','Off'
'PUBLIC','Auditing_options','4294967295'
'PUBLIC','Auto_commit','Off'
'PUBLIC','Auto_refetch','On'
'PUBLIC','Automatic_timestamp','Off'
'PUBLIC','Background_priority','Off'
'PUBLIC','Bell','On'
'PUBLIC','Blob_threshold','256'
'PUBLIC','Blocking','On'
'PUBLIC','Blocking_timeout','0'
'PUBLIC','Chained','On'
'PUBLIC','Char_OEM_Translation','Detect'
'PUBLIC','Checkpoint_time','60'
'PUBLIC','Cis_option','0'
'PUBLIC','Cis_rowset_size','50'
'PUBLIC','Close_on_endtrans','On'
'PUBLIC','Collect_statistics_on_dml_updates','On'
'PUBLIC','Command_delimiter','
'PUBLIC','Commit_on_exit','On'
'PUBLIC','Compression','6'
'PUBLIC','Connection_authentication',''
'PUBLIC','Continue_after_raiserror','OFF'
'PUBLIC','Conversion_error','On'
'PUBLIC','Cooperative_commit_timeout','250'
'PUBLIC','Cooperative_commits','On'
'PUBLIC','Database_authentication',''
'PUBLIC','Date_format','YYYY-MM-DD'
'PUBLIC','Date_order','YMD'
'PUBLIC','Debug_messages','Off'
'PUBLIC','Dedicated_task','Off'
'PUBLIC','Default_timestamp_increment','1'
'PUBLIC','Delayed_commit_timeout','500'
'PUBLIC','Delayed_commits','Off'
'PUBLIC','Delete_old_logs','Off'
'PUBLIC','Describe_Java_Format','Varchar'
'PUBLIC','Divide_by_zero_error','On'
'PUBLIC','Echo','On'
'PUBLIC','Escape_character','On'
'PUBLIC','Exclude_operators',''
'PUBLIC','Extended_join_syntax','On'
'PUBLIC','External_remote_options','Off'
'PUBLIC','Fire_triggers','On'
'PUBLIC','First_day_of_week','7'
'PUBLIC','Float_as_double','Off'
'PUBLIC','For_xml_null_treatment','Omit'
'PUBLIC','Force_view_creation','Off'
'PUBLIC','Global_database_id','103'
'PUBLIC','Headings','On'
'PUBLIC','Input_format','ASCII'
'PUBLIC','Integrated_server_name',''
'PUBLIC','Isolation_level','0'
'PUBLIC','ISQL_command_timing','On'
'PUBLIC','ISQL_escape_character','\\'
'PUBLIC','ISQL_field_separator',','
'PUBLIC','ISQL_log',''
'PUBLIC','ISQL_plan','Graphical'
'PUBLIC','ISQL_plan_cursor_sensitivity','ASENSITIVE'
'PUBLIC','ISQL_plan_cursor_writability','On'
'PUBLIC','ISQL_quote',''''
'PUBLIC','Java_heap_size','1000000'
'PUBLIC','Java_input_output','Off'
'PUBLIC','Java_namespace_size','4000000'
'PUBLIC','Java_page_buffer_size','50'
'PUBLIC','Lock_rejected_rows','Off'
'PUBLIC','Log_deadlocks','Off'
'PUBLIC','Log_detailed_plans','On'
'PUBLIC','Log_max_requests','100'
'PUBLIC','Login_mode','Standard'
'PUBLIC','Login_procedure','sp_login_environment'
'PUBLIC','Max_cursor_count','50'
'PUBLIC','Max_hash_size','10'
'PUBLIC','Max_plans_cached','20'
'PUBLIC','Max_recursive_iterations','100'
'PUBLIC','Max_statement_count','50'
'PUBLIC','Max_work_table_hash_size','20'
'PUBLIC','Min_password_length','0'
'PUBLIC','Nearest_century','0'
'PUBLIC','Non_keywords',''
'PUBLIC','NULLS','(NULL)'
'PUBLIC','ODBC_describe_binary_as_varbinary','Off'
'PUBLIC','ODBC_distinguish_char_and_varchar','Off'
'PUBLIC','On_Charset_conversion_failure','Ignore'
'PUBLIC','On_error','Prompt'
'PUBLIC','On_tsql_error','Conditional'
'PUBLIC','Optimistic_wait_for_commit','Off'
'PUBLIC','Optimization_goal','Response-time'
'PUBLIC','Optimization_level','9'
'PUBLIC','Optimization_logging','Off'
'PUBLIC','Optimization_workload','Mixed'
'PUBLIC','Output_format','ASCII'
'PUBLIC','Output_length','0'
'PUBLIC','Output_nulls',''
'PUBLIC','Percent_as_comment','On'
'PUBLIC','Pinned_cursor_percent_of_cache','10'
'PUBLIC','Precision','30'
'PUBLIC','Prefetch','On'
'PUBLIC','Preserve_source_format','On'
'PUBLIC','Prevent_article_pkey_update','On'
'PUBLIC','Qualify_owners','On'
'PUBLIC','Query_plan_on_open','Off'
'PUBLIC','Quiet','Off'
'PUBLIC','Quote_all_identifiers','Off'
'PUBLIC','Quoted_identifier','On'
'PUBLIC','Read_past_deleted','On'
'PUBLIC','Recovery_time','2'
'PUBLIC','Remote_idle_timeout','15'
'PUBLIC','Replicate_all','Off'
'PUBLIC','Replication_error',''
'PUBLIC','Replication_error_piece',''
'PUBLIC','Return_date_time_as_string','Off'
'PUBLIC','Return_java_as_string','Off'
'PUBLIC','RI_Trigger_time','After'
'PUBLIC','Rollback_on_deadlock','On'
'PUBLIC','Row_counts','Off'
'PUBLIC','Save_remote_passwords','On'
'PUBLIC','Scale','6'
'PUBLIC','Screen_format','Text'
'PUBLIC','Sort_Collation','Internal'
'PUBLIC','SQL_flagger_error_level','W'
'PUBLIC','SQL_flagger_warning_level','W'
'PUBLIC','SQLConnect',''
'PUBLIC','SQLStart',''
'PUBLIC','SR_Date_Format','yyyy/mm/dd'
'PUBLIC','SR_Time_Format','hh:nn:ss.Ssssss'
'PUBLIC','SR_TimeStamp_Format','hh:nn:ss.Ssssss yyyy/mm/dd'
'PUBLIC','Statistics','3'
'PUBLIC','String_rtruncation','Off'
'PUBLIC','Subscribe_by_remote','On'
'PUBLIC','Subsume_row_locks','On'
'PUBLIC','Suppress_TDS_debugging','Off'
'PUBLIC','TDS_Empty_string_is_null','Off'
'PUBLIC','Temp_space_limit_check','Off'
'PUBLIC','Thread_count','0'
'PUBLIC','Thread_stack','750'
'PUBLIC','Thread_swaps','18'
'PUBLIC','Time_format','HH:NN:SS.SSS'
'PUBLIC','Time_zone_adjustment','0'
'PUBLIC','Timestamp_format','YYYY-MM-DD HH:NN:SS.SSS'
'PUBLIC','Truncate_date_values','On'
'PUBLIC','Truncate_timestamp_values','Off'
'PUBLIC','Truncate_with_auto_commit','On'
'PUBLIC','Truncation_length','30'
'PUBLIC','Tsql_hex_constant','On'
'PUBLIC','Tsql_variables','Off'
'PUBLIC','Update_statistics','On'
'PUBLIC','User_estimates','Override-magic'
'PUBLIC','UUID_has_hyphens','On'
'PUBLIC','Verify_all_columns','Off'
'PUBLIC','Verify_password_function',''
'PUBLIC','Verify_threshold','1000'
'PUBLIC','Wait_for_commit','Off'
'PUBLIC','Webservice_namespace_host',''


Reg Domaratzki Posted on 2005-12-15 05:36:39.0Z
From: "Reg Domaratzki" <nospam.please@sympatico.ca>
Newsgroups: sybase.public.ase.replicator
References: <43a04b4c.1fc8.1681692777@sybase.com>
Subject: Re: Cannot Update Primary Key Value with dbremote.exe
Lines: 256
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2800.1506
X-MIMEOLE: Produced By Microsoft MimeOLE V6.00.2800.1506
NNTP-Posting-Host: quebec-hse-ppp3614222.sympatico.ca
X-Original-NNTP-Posting-Host: quebec-hse-ppp3614222.sympatico.ca
Message-ID: <43a100e7$1@forums-1-dub>
Date: 14 Dec 2005 21:36:39 -0800
X-Trace: forums-1-dub 1134624999 65.93.199.65 (14 Dec 2005 21:36:39 -0800)
X-Original-Trace: 14 Dec 2005 21:36:39 -0800, quebec-hse-ppp3614222.sympatico.ca
X-Authenticated-User: techsupp
Path: forums-1-dub!not-for-mail
Xref: forums-1-dub sybase.public.ase.replicator:121
Article PK: 103357

Please do not cross post. I've answered your question on the SQL Remote
newsgroup, which was the appropriate forum for this question.

--
Reg Domaratzki, Sybase iAnywhere Solutions
Certified SQL Anywhere Associate
Please reply only to the newsgroup

ASA Patches and EBFs : http://downloads.sybase.com/swx/sdmain.stm
-> Choose SQL Anywhere Studio
-> Set "Platform Preview" and "Time Frame" to ALL and click "GO"


<bienkowm> wrote in message news:43a04b4c.1fc8.1681692777@sybase.com...
Please help me !!!


I have ASE 9.0.2.3221 version and use to I have ASE 7.0.
After upgrade database to the latest version I have a huge
problem w dbremote replication. I found a post at forum
site
its very similar problem

"Cannot update primary key for table"


http://groups.google.pl/group/sybase.public.sqlanywhere.mobilink/browse_thread/thread/5bafa6c83e7a9fcd/536954ae19637d0f?lnk=st&q="SQL+statement+failed:+(-780)+Cannot+update+primary+key+for+table"&rnum=2&hl=pl#536954ae19637d0f

This is my problem !!!!

Piece of replication log (name of file - look below
"Agent dbremote.exe setting(dbremote)")):


I. 12/14 16:31:19. UPDATE DBA.zl
SET id_st_z='A',
id_kom='WA051214163001019802',
czas='16:30:01.715 2005/12/14',
id_work='tester'
VERIFY (czas, id_work)
VALUES (NULL,NULL) WHERE
cur_data='2005/12/14' AND
department='22222249' AND nr='49'
AND nrzlec=55555555
AND id_st_z ='R' AND
id_w_z='W'

SQL statement failed: (-780) Cannot update primary key for
table 'zl' involved in a publication
E. 12/14 16:31:20. Skipping:
E. 12/14 16:31:20. UPDATE DBA.zl

id_st_z - is a primary key and as I sad I cannot change
it. How can I resolve that problem ???

I CANNOT INTERFERE IN STRUCTURE AND DATA IN DATABASE BECAUSE
IM NOT A DESIGNER.





ASE and remote database configuration details

ASE Version:

9.0.2.3221


Agent dbremote.exe setting(dbremote)

-c "uid=db_remote;pwd=xxxxxxxx;eng= testPRDOZ
" -t -v -o C:\replication.log

Remote dbsrv9.exe database setting

-n testPRDOZ
-c 16M
-gm 20
-gf
-x tcpip
"E:\Baza\test\PRD\testPRD.db"

Database options:



'DBA','Date_order','YMD'
'DBA','ISQL_command_timing','On'
'DBA','ISQL_plan','Graphical'
'DBA','On_error','Prompt'
'DBA','Prevent_article_pkey_update','OFF'
'PUBLIC','Allow_nulls_by_default','On'
'PUBLIC','Allow_replication_pkey_update','On'
'PUBLIC','Allow_sync_pkey_update','On'
'PUBLIC','Ansi_blanks','Off'
'PUBLIC','Ansi_close_cursors_on_rollback','Off'
'PUBLIC','Ansi_integer_overflow','Off'
'PUBLIC','Ansi_permissions','On'
'PUBLIC','Ansi_update_constraints','Off'
'PUBLIC','Ansinull','On'
'PUBLIC','Assume_distinct_servers','Off'
'PUBLIC','Auditing','Off'
'PUBLIC','Auditing_options','4294967295'
'PUBLIC','Auto_commit','Off'
'PUBLIC','Auto_refetch','On'
'PUBLIC','Automatic_timestamp','Off'
'PUBLIC','Background_priority','Off'
'PUBLIC','Bell','On'
'PUBLIC','Blob_threshold','256'
'PUBLIC','Blocking','On'
'PUBLIC','Blocking_timeout','0'
'PUBLIC','Chained','On'
'PUBLIC','Char_OEM_Translation','Detect'
'PUBLIC','Checkpoint_time','60'
'PUBLIC','Cis_option','0'
'PUBLIC','Cis_rowset_size','50'
'PUBLIC','Close_on_endtrans','On'
'PUBLIC','Collect_statistics_on_dml_updates','On'
'PUBLIC','Command_delimiter','
'PUBLIC','Commit_on_exit','On'
'PUBLIC','Compression','6'
'PUBLIC','Connection_authentication',''
'PUBLIC','Continue_after_raiserror','OFF'
'PUBLIC','Conversion_error','On'
'PUBLIC','Cooperative_commit_timeout','250'
'PUBLIC','Cooperative_commits','On'
'PUBLIC','Database_authentication',''
'PUBLIC','Date_format','YYYY-MM-DD'
'PUBLIC','Date_order','YMD'
'PUBLIC','Debug_messages','Off'
'PUBLIC','Dedicated_task','Off'
'PUBLIC','Default_timestamp_increment','1'
'PUBLIC','Delayed_commit_timeout','500'
'PUBLIC','Delayed_commits','Off'
'PUBLIC','Delete_old_logs','Off'
'PUBLIC','Describe_Java_Format','Varchar'
'PUBLIC','Divide_by_zero_error','On'
'PUBLIC','Echo','On'
'PUBLIC','Escape_character','On'
'PUBLIC','Exclude_operators',''
'PUBLIC','Extended_join_syntax','On'
'PUBLIC','External_remote_options','Off'
'PUBLIC','Fire_triggers','On'
'PUBLIC','First_day_of_week','7'
'PUBLIC','Float_as_double','Off'
'PUBLIC','For_xml_null_treatment','Omit'
'PUBLIC','Force_view_creation','Off'
'PUBLIC','Global_database_id','103'
'PUBLIC','Headings','On'
'PUBLIC','Input_format','ASCII'
'PUBLIC','Integrated_server_name',''
'PUBLIC','Isolation_level','0'
'PUBLIC','ISQL_command_timing','On'
'PUBLIC','ISQL_escape_character','\\'
'PUBLIC','ISQL_field_separator',','
'PUBLIC','ISQL_log',''
'PUBLIC','ISQL_plan','Graphical'
'PUBLIC','ISQL_plan_cursor_sensitivity','ASENSITIVE'
'PUBLIC','ISQL_plan_cursor_writability','On'
'PUBLIC','ISQL_quote',''''
'PUBLIC','Java_heap_size','1000000'
'PUBLIC','Java_input_output','Off'
'PUBLIC','Java_namespace_size','4000000'
'PUBLIC','Java_page_buffer_size','50'
'PUBLIC','Lock_rejected_rows','Off'
'PUBLIC','Log_deadlocks','Off'
'PUBLIC','Log_detailed_plans','On'
'PUBLIC','Log_max_requests','100'
'PUBLIC','Login_mode','Standard'
'PUBLIC','Login_procedure','sp_login_environment'
'PUBLIC','Max_cursor_count','50'
'PUBLIC','Max_hash_size','10'
'PUBLIC','Max_plans_cached','20'
'PUBLIC','Max_recursive_iterations','100'
'PUBLIC','Max_statement_count','50'
'PUBLIC','Max_work_table_hash_size','20'
'PUBLIC','Min_password_length','0'
'PUBLIC','Nearest_century','0'
'PUBLIC','Non_keywords',''
'PUBLIC','NULLS','(NULL)'
'PUBLIC','ODBC_describe_binary_as_varbinary','Off'
'PUBLIC','ODBC_distinguish_char_and_varchar','Off'
'PUBLIC','On_Charset_conversion_failure','Ignore'
'PUBLIC','On_error','Prompt'
'PUBLIC','On_tsql_error','Conditional'
'PUBLIC','Optimistic_wait_for_commit','Off'
'PUBLIC','Optimization_goal','Response-time'
'PUBLIC','Optimization_level','9'
'PUBLIC','Optimization_logging','Off'
'PUBLIC','Optimization_workload','Mixed'
'PUBLIC','Output_format','ASCII'
'PUBLIC','Output_length','0'
'PUBLIC','Output_nulls',''
'PUBLIC','Percent_as_comment','On'
'PUBLIC','Pinned_cursor_percent_of_cache','10'
'PUBLIC','Precision','30'
'PUBLIC','Prefetch','On'
'PUBLIC','Preserve_source_format','On'
'PUBLIC','Prevent_article_pkey_update','On'
'PUBLIC','Qualify_owners','On'
'PUBLIC','Query_plan_on_open','Off'
'PUBLIC','Quiet','Off'
'PUBLIC','Quote_all_identifiers','Off'
'PUBLIC','Quoted_identifier','On'
'PUBLIC','Read_past_deleted','On'
'PUBLIC','Recovery_time','2'
'PUBLIC','Remote_idle_timeout','15'
'PUBLIC','Replicate_all','Off'
'PUBLIC','Replication_error',''
'PUBLIC','Replication_error_piece',''
'PUBLIC','Return_date_time_as_string','Off'
'PUBLIC','Return_java_as_string','Off'
'PUBLIC','RI_Trigger_time','After'
'PUBLIC','Rollback_on_deadlock','On'
'PUBLIC','Row_counts','Off'
'PUBLIC','Save_remote_passwords','On'
'PUBLIC','Scale','6'
'PUBLIC','Screen_format','Text'
'PUBLIC','Sort_Collation','Internal'
'PUBLIC','SQL_flagger_error_level','W'
'PUBLIC','SQL_flagger_warning_level','W'
'PUBLIC','SQLConnect',''
'PUBLIC','SQLStart',''
'PUBLIC','SR_Date_Format','yyyy/mm/dd'
'PUBLIC','SR_Time_Format','hh:nn:ss.Ssssss'
'PUBLIC','SR_TimeStamp_Format','hh:nn:ss.Ssssss yyyy/mm/dd'
'PUBLIC','Statistics','3'
'PUBLIC','String_rtruncation','Off'
'PUBLIC','Subscribe_by_remote','On'
'PUBLIC','Subsume_row_locks','On'
'PUBLIC','Suppress_TDS_debugging','Off'
'PUBLIC','TDS_Empty_string_is_null','Off'
'PUBLIC','Temp_space_limit_check','Off'
'PUBLIC','Thread_count','0'
'PUBLIC','Thread_stack','750'
'PUBLIC','Thread_swaps','18'
'PUBLIC','Time_format','HH:NN:SS.SSS'
'PUBLIC','Time_zone_adjustment','0'
'PUBLIC','Timestamp_format','YYYY-MM-DD HH:NN:SS.SSS'
'PUBLIC','Truncate_date_values','On'
'PUBLIC','Truncate_timestamp_values','Off'
'PUBLIC','Truncate_with_auto_commit','On'
'PUBLIC','Truncation_length','30'
'PUBLIC','Tsql_hex_constant','On'
'PUBLIC','Tsql_variables','Off'
'PUBLIC','Update_statistics','On'
'PUBLIC','User_estimates','Override-magic'
'PUBLIC','UUID_has_hyphens','On'
'PUBLIC','Verify_all_columns','Off'
'PUBLIC','Verify_password_function',''
'PUBLIC','Verify_threshold','1000'
'PUBLIC','Wait_for_commit','Off'
'PUBLIC','Webservice_namespace_host',''