9i Replication - new to
Hi folks,
I am new to 9i Replication - and replication in general!
I want to replicate specific objects in one schema on a database to a different schema and on a different database.
Could someone point me in the right direction. I have read all the 9i Replication manuals, but I am looking for some smaller-, to-the-point docs.
Thanks in advance,
Will
If you know the basics of replication then chapter 2 and 3 of the following link can help you.
http://download-uk.oracle.com/docs/cd/B19306_01/server.102/b14227/toc.htm
-aijaz
Similar Messages
-
Vendor payment terms replication
Hi,
Vendor payment terms are not getting replicated to SRM 4.0 from ECC 5.0.We have batch jobs running for vendor replication ( new and update).When i change the payment terms in ECC , it is not coming to SRM.I checked in Manage BPs.
Thanks for suggesting any report / tables where i can find number of vendors that are different in both the systems and replication process. ( As i am unable to use the t code BBPGETVD, BBPUPDVD in easyaccess)
Thanks a lot.Hi pramod,
OK. I got it.
SAP Note 1104581 -No logical system in customizing view
BBPV_PTERM_LOCAL
Symptom
You have transported local payment term Customizing (view BBPV_PTERM_LOCAL)
from your SRM development system to a productive system.
The transported payment terms cannot be selected for local purchase orders
and are not visible in Customizing step "Supplier Relationship Management >
SRM Server > Cross-Application Basic Settings > Create Payment Conditions".
More TermsZTERM, pay, BBP_POC, payment tab, terms of payment
Cause and Prerequisites
Local payment terms must have the local logical system ID in the
corresponding fields of tables BBP_PAYTERM and BBP_PAYTERM_TEXT.
Solution
Please implement this note or the relevant Support Package.
You can then use report BBPCU_PAYTERM_CONV to change the logical system of
the transported entries to the local SRM logical system.
In the single selection parameter, enter the logical system of the
transported entries.
An error will be generated if the entered logical system exists in table
BBP_BACKEND_DEST.
If an entry already exists with the same key (apart from logical system
name) as the tranported entry, no conversion will take place.
The keys of the converted payment terms and their texts will be listed
after executing the program.
The keys of the payment terms that cannot be converted will also be lsited.
table BBP_PAYTERM or BBP_PAYTERM_TEXT.
BBPM_BUT_FRG0061
Payment conditions
i will also check and come back to you.
regards
muthu -
Run something once in a cluster environment
I'm looking at using JBoss Cache to cache a large amount of data. If you're unfamiliar with JC, it's a cachine system that will synchronize multiple remote caches in a clustered environment. However, I don't want each cache to load itself at cluster startup, and then sync with all the other caches - there's a lot of data, and I don't want all the caches to become really chatty during startup for performance reasons. I would rather have one server instance act as the master cache, and then have it sync all the other empty caches...
I therefore need a way to determine what node in the cluster I'm running on. How can I programatically do this? I've looked through the API's, but it's like trying to find a needle in a haystack...Hi Ken,
Ok, at least according t its documentation the jboss cache will deal in its own with the failure detection, replication, new servers joining, which answers my curiosity in the upper memo
I was speaking of servers later than NW 2004, but here is a suggestion how to deal with NW 2004:
In order to achieve your goal - "prefetch everything only on one node", you could play with the locking feature. Here is a possible algorithm that could be put in code executed at application start (servlet init method, etc.):
1) Check if the cache is empty, if it is not, you are secondary and someone has already updated you - exit
2) Try to take a cluster unique logical lock in the locking service (here is the <a href="http://help.sap.com/saphelp_erp2005/helpdata/en/9a/4cdcc80fa4c747a2ccb5859f467412/frameset.htm">locking documentation</a>
)If you cannot take the lock- you are the secondary server and someone is refreshing the cache at the moment, exit
3) Update the cache
4) Release the lock
If there is no API to check if the cache is empty, you could potentially use some variable that is part of the cache and will be replicated to all servers. Before releasing the lock, you put some value "CacheUpdated" there.
Another option would be to use some hardcoded logic and workarounds - do something only for specific server id as suggested in upper memo, do something if there is a specific property (System.getProperty()...) that you would put manually in only one server JVM startup options.
Perhaps the simplest solution is to turn off all the cache prefetching - i.e. all nodes will start with empty cache and will load data on demand. You won't screw the performance of the "master" server as well.
HTH
Peter -
New table/column in publication breaks replication
Hi,
SQL 2008R2
I added a control table to a database that is being replicated to a different server. The tabled called [__Updated] has one column called [DateUpdated] of type datetime2. I manually created the table in the subscriber, added the new table/column
to the list of articles and ran the replication.
It falls over with the error shown below, any ideas?
2015-02-24 16:23:34.32 [95%] Generating schema scripts for article 'AAA'
2015-02-24 16:23:34.32 [95%] Generating schema scripts for article '__Updated'
2015-02-24 16:23:34.33 [95%] The replication agent had encountered an exception.
2015-02-24 16:23:34.33 Source: Unknown
2015-02-24 16:23:34.33 Exception Type: Microsoft.SqlServer.Management.Smo.FailedOperationException
2015-02-24 16:23:34.33 Exception Message: Script failed for Table 'dbo.__Updated'.
2015-02-24 16:23:34.33 Message Code: Not Applicable
2015-02-24 16:23:34.33
Exact version is:
SELECT @@VERSION
Microsoft SQL Server 2008 R2 (SP2) - 10.50.4000.0 (X64)
Jun 28 2012 08:36:30
Copyright (c) Microsoft Corporation
Standard Edition (64-bit) on Windows NT 6.2 <X64> (Build 9200: ) (Hypervisor)Replication is considered to be a mature technology which means there are little changes. Oracle publishing is gone and updateable subcriptions are gone. Other than that it is the same.
looking for a book on SQL Server 2008 Administration?
http://www.amazon.com/Microsoft-Server-2008-Management-Administration/dp/067233044X looking for a book on SQL Server 2008 Full-Text Search?
http://www.amazon.com/Pro-Full-Text-Search-Server-2008/dp/1430215941 -
In memory replication problems when I bring up a new server
I've got in memory replication set up for 6.1. It works fine if I have 2 servers
up and 1 goes down.
However, if I have 1 server up and a bring a second server up, the sessions blow
out.
E.g. I've got server A and server B.
Both are up, both have sessions. As new sessions come in, they are replicated over
to the other server.
now I bring server B down. All sessions on B fail over to A.
so far so good.
However when I bring server A back up some of the sessions fail as soon as the server
is back up.
Is this a configuration issue, is this a know problem?
This worked fine in weblogic 5.1. In 5.1 when I brought an instance back up, everything
worked fine.
It turns out the problem was caused by using an old version of the Apache Plugin.
This problem occurred while using the 5.1 apache plugin with WLS 6.1.
Once we realized we were using the wrong plugin and swithced to the 6.1 plugin, the
problem went away.
-
Replication of a new BP field form CRM to R/3
Hi Experts,
We use CRM 4.0. I have created a new field with EEWB in CRM and I would like to replicate this field to R/3. This is a standard field on R/3 side.
Could you please help me what are the steps to do for the replication? We use R/3 adapter and the BP replication works properly.
Thanks a lot in advance!
Regards,
TomHi Thomas,
Replication of new fields between CRM and R/3 will involve a few manual steps.
1. Ensure that that relevant Bdoc structure is also extended with the new field. EEWB should do this for you but i am not sure about CRM 40.
2. There needs to be a logic in the CRM outbound to map the new field to bapistructures. you will have to code a user exit for crm outbound in tx -
crmc_but_call_fu.
3. The R/3 adapter inbound also needs to be made aware of the new field. so necessary mapping to the R/3 standard field has to be done using tx.
comc_bupa_call_fu
Reward if this helps...
Regards,
Sudipta -
Transactional Replication - Generate a snapshot for a new art only
I will apreciate any help on this, thanks ahead!
We are running the below script that works well for us at dev and other environments but when running on prod the generated snapshot is for all articles in the publication rather than the desired results, for the new art only.
I have copied below the code being used.
SET NOCOUNT ON; SET TRANSACTION ISOLATION LEVEL READ COMMITTED;
DECLARE @rc int, @publication sysname, @article sysname, @subscriber sysname, @destination_db sysname
,@delete_article_from_replication_configuration bit ,@debug bit = 1;
SELECT @publication = N'MyPub'
,@destination_db = N'dest_database'
,@subscriber = N'MyServer'
SELECT @article = N'MyArt'
-- SET immediate_sync and allow_anonymous to false
EXEC sp_changepublication
@publication = @publication,
@property = N'immediate_sync',
@value = N'false';
EXEC sp_changepublication
@publication = @publication,
@property = N'allow_anonymous',
@value = N'false';
-- add article
DECLARE @error_message nvarchar(4000);
IF NOT EXISTS (SELECT * FROM dbo.sysarticles a INNER JOIN dbo.syspublications p ON a.pubid = p.pubid WHERE a.name = @article AND p.name = @publication)
BEGIN;
EXEC @rc = sp_addarticle
@publication = @publication
,@article = @article
,@source_owner = N'dbo'
,@source_object = @article
,@destination_table = @article
,@type = N'logbased'
,@creation_script = null
,@description = null
,@pre_creation_cmd = N'none'
,@schema_option = 0x000000000803100D /* 0x000000000803FFDF */
,@status = 16 /* 8 */
,@vertical_partition = N'false'
,@ins_cmd = N'SQL'
,@del_cmd = N'SQL'
,@upd_cmd = N'SQL'
,@filter = null
,@sync_object = null
,@auto_identity_range = N'false'
,@identityrangemanagementoption = N'manual';
IF ( (@@ERROR <> 0) OR (@rc <> 0) )
BEGIN;
SELECT @error_message = ERROR_MESSAGE(); RAISERROR(@error_message, 16, 1);
IF (@@TRANCOUNT > 0) ROLLBACK TRAN; RETURN;
END;
PRINT 'The article ''' + @article + ''' has been added to publication ''' + @publication + '''';
END;
-- add subscription
IF NOT EXISTS (SELECT * from syssubscriptions WHERE dest_db NOT LIKE 'virtual' AND srvname LIKE @subscriber AND artid IN
(SELECT artid FROM dbo.sysarticles a INNER JOIN dbo.syspublications p ON a.pubid = p.pubid WHERE a.name = @article AND p.name = @publication ))
BEGIN;
EXEC @rc = sp_addsubscription
@publication = @publication
,@subscriber = @subscriber
,@destination_db = @destination_db
,@subscription_type = N'Pull'
,@sync_type = N'automatic'
--,@sync_type = N'replication support only'
,@article = @article
,@update_mode = N'read only'
,@subscriber_type = 0
,@subscriptionstreams = 4;
IF ( (@@ERROR <> 0) OR (@rc <> 0) )
BEGIN;
SELECT @error_message = ERROR_MESSAGE(); RAISERROR(@error_message, 16, 1);
IF (@@TRANCOUNT > 0) ROLLBACK TRAN; RETURN;
END;
PRINT 'The subscription ''' + @subscriber + ''' for article ''' + @article + ''' has been created''';
END;
EXEC sp_changepublication
@publication = @publication
,@property = N'sync_method'
,@value = N'native'
,@force_invalidate_snapshot = 0
,@force_reinit_subscription = 0;
-- create snapshot
EXEC sp_addpublication_snapshot
@publication = @publication
,@frequency_type = 1
,@frequency_interval = 1
,@frequency_relative_interval = 0
,@frequency_recurrence_factor = 0
,@frequency_subday = 0
,@frequency_subday_interval = 0
,@active_start_time_of_day = 0
,@active_end_time_of_day = 235959
,@active_start_date = 0
,@active_end_date = 0;
Yaniv Etrogi
site |
blog | linked in |
mail
Please click the Mark as Answer button if a post solves your problem! or
Vote As HelpfulHello,
1. Verify if you are using CONCURRENT or NATIVE method for synchronization by running the following command.
Use yourdb
select sync_method from syspublications
If the value is 3 or 4 then it is CONCURRENT and if it is 0 then it is NATIVE.
For more information check
http://msdn.microsoft.com/en-us/library/ms189805.aspx
2) Then add the subscription for this new article using the following command
EXEC sp_addsubscription @publication = 'yourpublication', @article = 'test',
@subscriber =‘subs_servername', @destination_db = 'subs_DBNAME',
@reserved='Internal'
If you are using the NATIVE method for synchronization then the parameter
@reserved=’Internal’ is optional but there is no harm in using it anyways. But if it is CONCURRENT then you have to use that parameter. Else the next time you run the snapshot agent it is going to generate a snapshot for all the articles.
Lastly start the SNAPSHOT AGENT job from the job activity monitor. To find
the job name follow these steps.
· select * from msdb..sysjobs where name like '%yourpublication%'
· Right click on each of those jobs and find which one contains the step
‘Snapshot Agent startup message’. This is the job that you want to
start from the first step.
3. Verify that the snapshot was generated for only one article.
Regards, Pradyothana DP. Please Mark This As Answer if it solved your issue. Please Mark This As Helpful if it helps to solve your issue. ========================================================== http://www.dbainhouse.blogspot.in/ -
Hi,
I am in process of setting up Oracle Streams schema level replication on version 10.2.0.3. I am able to setup replication for one table properly. Now I want to add 10 more new tables for schema level replication. Few questions regarding this
1. If I create new tables in source, shall I have to create tables in target database manually or I have to do export STREAMS_INSTANTIATION=Y
2. Can you tell me metalink note id to read more on this topic ?
thanks & regards
paragThe same capture and apply process can be used to replicate other tables. Following steps should suffice your need:
Say table NEW is the new table to be added with owner SANTU
downstr_cap is the capture process which is already running
downstr_apply is the apply process which is already there
1. Now stop the apply process
2. Stop the capture process
3. Add the new table in the capture process using +ve rule
BEGIN
DBMS_STREAMS_ADM.ADD_TABLE_RULES
table_name => 'SANTU.NEW',
streams_type => 'capture',
streams_name => 'downstr_cap',
queue_name => 'strmadmin.DOWNSTREAM_Q',
include_dml => true,
include_ddl => true,
source_database => ' Name of the source database ',
inclusion_rule => true
END;
4. Take export of the new table with "OBJECT_CONSISTENT=Y" option
5. Import the table at destination with "STREAMS_INSTANTIATION=Y' option
6. Start the apply process
7. Start the capture process -
How to change datasource type 3.x or new after replication?
Hello,
after the replication of a datasource i got a popup, if i want an old 3.X datasource or a new datasource. I clicked new, but i need an old 3.x datasource. Now i don't have a chance the change this.Where can i do it?
I deleted the datasource in sourcesystem, but after new replication i don't get the popup to choose the datasource type.
The problem is, i can't change the technical name of the datasource in sourcesystem because of the naming convention.
Thanks in advance.
Regards.Hi Bill,
it's a generic datasource i created.The problem is that i create a 3.x Infosource too and i want use my generic datasource. But after replication i choose the false type (new datasource and not 3.x datasource) and now i can't assign my datasource to my 3.x infosource.I see the datasource in the sourcesystem-tree but not in the infosource-datasource-assigning-Popup.
How can i change the type of datasource from new datasource to 3.x datasource in BI 7.0??? -
GWI: Add new filter criteria for replication object BUPA_MAIN
Hello,
we are currently setting up Groupware Integration with CRM 7.0 and Outlook Exchange 2007. We would like to filter the BPs that are replicated to Outlook's public folder. The replication object BUPA_MAIN in Tx. SMOEAC has only got the following criteria fields:
BPARTNER
CENTRALARCHIVINGFLAG
COUNTRYISO
INDUSTRY
IS_COMPETITOR
IS_CONSUMER
IS_CUSTOMER
IS_DELETED
IS_PROSPECT
PARTNEREXTERNAL
REGION
SEARCHTERM1
SEARCHTERM2
SITE_ID
We don't want to use any of those but would like to set a filter on BP Role and filter for all Groupware Employees. Only those should be replicated.
We did set the filter conditions in customizing under "Filter Condition for Business Partners Exchange with Groupware" in order to replicate only BP with role GWEMP but still during Initial Load all Business Partners were replicated.
Could anyone tell me how to avoid this?
I hear it's possible to add new criteria fields to the replication object BUPA_MAIN.
Could anyone tell me how this is done?
Your help will be much appreciated.
Thanks in advance!
AngelaHello Angela
Usually the settings under "Filter Condition for Business Partners Exchange with Groupware" should be enough to avoid the synchronization. With those settings all BP are filtered out except the ones with role GWEMP (Groupware Employee).
We have the following setting in SPRO:
BUPA 1 BUP001 X X
BUPA 1 BUP003 X X
BUPA 2 X X
BUPA 3 X X
(first column empty, second and third column with X, last column empty).
Regards
Marco -
MOVE REPLICATION DATABASE TO NEW SERVER
WE HAVE A PRODUCTION DATABASE THAT WORK'S AS REPLICATION FROM 9 DATABASES, WE ARE GOING TO MOVE DATABASE TO NEW SERVER.
AS DATABASE IS PRODUCTION, WE CAN NOT STOP SERVICES. WE THINK TO CREATE A NEW DATABASE ON NEW SERVER, IMPORT DATA FROM PROD. DATABASE. SIZE APROX 100GB.
QUESTION:
I NEED TO KNOW HOW I CAN STOP SERVICES SHORT TIME. TO CHANGE TO SNEW SERVER.
THANKS FOR YOUR SUGGESTIONSЗдравствуте Ivan.
Before i would do anything like this i would make sure that i have a good valid backup (just in case!).
I would check all the applications that are currently conencting to your ORacle and make sure they are all conneting 'by name' not the IP. Or and then i would check DNS server (make sure nslookup is working) to makesure that everything resolves correctly after the moving DB to another machine.
Then check that the oracle_home etc are in the same directory and check that all paths etc in the configurations are the same.
Hope this helps
Kind Regards -
Best Practice Adding New Target to Namespace and Replication
Hi,
whats the best way to add a new target to Namespace and replication. Goal is to replace a old file Server at the end.
I did the following:
- copied the share with robocopy incl timestamps of files and folders
- created share
- added the new share as a new target as well as meshd member of the replication connection
- disabled the new member in the Namespace, so no one can Access it until dfsr is fully done and initialized
After the the new dfsr Connection was replicated through AD to all 4 Members (3 different site, 1 same site) the
following happend:
dfsr begin and almost every file was in a conflicted and copied over the the Conflict Folder. Almost all timestamps
of the Folders were changed to the current date, but the timestamps of the files not.
Thousands of eventlogs: 4412
The DFS Replication service detected that a file was changed on multiple servers. A conflict resolution algorithm was used to determine the winning file. The losing file was moved to the Conflict and Deleted folder.
Any idea why? Later on i disabled the Connections to the remote Fileservers, but that did not stop it.
My idea was to pre-seed the files with robocopy. So what would be the best way to prevent that for the next share ? Is it a better way to just add the target to a bi-directional Connection to the local Fileserver without adding to DFS-N and without copying
the files before ? Is it better to let DFSR do the hole Initial sync incl Files ?
At the end i have no loss of date but to check almost every file for conflict took Ages to finish.
Thanks a lot,
MarcoHi,
The steps you performed are correct - compare with waiting for DFS initial replication, a manually pre-staging is recommended.
When doing the Robocopy step, wether all attributes are copied such as NTFS permissions?
After robocopy, you can add that folder as a folder target of DFS replication group - you can add it to DFS namespace after replication finished.
And if it is a Windows 2012 R2, you can prestaging DFS database for a better result.
https://social.technet.microsoft.com/Forums/windows/en-US/a06c9d25-ed04-44e9-a1f7-e1506e645d53/forum-faq-how-to-prestaging-dfsr-database-on-windows-server-2012-r2?forum=winserverfiles
Please remember to mark the replies as answers if they help and un-mark them if they provide no help. If you have feedback for TechNet Support, contact [email protected] -
SQL Server Transacational Replication Issue while adding a new article
I have a "PULL" transaction replication toplogy (SQL server 2008 R2 - publisher,subscriber & distributor) in place and is working fie. I added a new article (table) using sp_addarticle and it works fine. Then I tried to add subscription
to the new article using sp_adddsubscrition SPROC from the publisher (details below)
EXEC sp_addsubscription @publication = @pub_name, @article = @article_name, @subscriber = @sub_server, @destination_db
= @sub_dbname, @subscription_type = N'pull',@update_mode = N'read only', @sync_type = 'sutomatic', @status = 'active',
@reserved ='Internal'
I tried with all combination of values in the @sync_type parametr,
The above command fails with the following message:
Msg 14100, Level 16, State 1, Procedure sp_MSrepl_addsubscription, Line 533;
Specify all articles when subscribing to a publication using concurrent snapshot processing.
The sync_type value parameter is "replication support type" when the subscrition was added orginally to the publication. This trsnslates into a value of 3 (CONCURRENT) in sync_method
column on the outpout of sp_helppublication SP execution.
What am I doing wrong? Please advise. Your help is much appreciated.
Thanks in advance
KirtiThanks for your reposne, Mr. Cottr.
It was a type-oin the value for @sync_type parameter in the sp_addsubscription call when I posted this article originally. It was actually set to "automatic". I have posted the scripts per your request. These scripts are executed in SQLCMD mode in
SSMS query qindow. Since this is a PULL subscription, thre is another script for pP-addpullsubscription that is not incldued in this post. If you need that also, I will be glald to post that also. Thanks again for your help.
-->>>>>sp_addpublication:
USE [master]
GO
SQL Server Transactional Replication Related Scripts
Function: Configuring publication on the database at the publisher
-- TO DO: Parameters to set before executing this TSQL batch script
:SETVAR pub_dbname TestDB
:SETvar pub_name TestDB-TranPub01
:SETVAR distributor DISTRIBSVR
:SETVAR repl_admin_account <domain>\<account_name>
--replication admin account for non-prod environment
:SETVAR repl_admin_password <pwd>
--password for replication admin account
USE [$(pub_dbname)]
SET NOCOUNT ON
IF db_name() IN ('master', 'model', 'msdb', 'tempdb', 'distribution', 'DBA')
BEGIN
RAISERROR('Please set the user database name properly and rerun the script', 15, 100)
RETURN
END
DECLARE @dynsql sysname
,@repl_ddl int
,@allow_initialize_from_backup varchar(5)
SET @repl_ddl = 1 -- preferred value is 0 (replication of DDL statements prohibited; manually enabled
when needed only)
SET @allow_initialize_from_backup = 'true' -- preferred /do not change this value
-- Adding the transactional publication
DECLARE @desc varchar(255)
SET @desc = 'Transactional replication of database ' + QUOTENAME('$(pub_dbname)') +
' from publisher ' + QUOTENAME(@@servername) + '; Publication: ' + QUOTENAME('$(pub_name)')
PRINT '1. Configureing publication ' + QUOTENAME('$(pub_name)') + ' on database ' + QUOTENAME('$(pub_dbname)') + ' ...'
EXEC sp_addpublication
@publication = '$(pub_name)',
@description = @desc,
@retention = 0,
@add_to_active_directory = N'false',
@allow_push = N'false', -- push subscription disabled
@allow_pull = N'true', -- pull subscription enabled
@allow_anonymous = N'false',
@allow_sync_tran = N'false',
@allow_queued_tran = N'false',
@allow_dts = N'false',
@allow_initialize_from_backup = @allow_initialize_from_backup,
@allow_subscription_copy = N'false',
@compress_snapshot = N'false',
@enabled_for_internet = N'false',
@enabled_for_p2p = N'false',
@independent_agent = N'true',
@immediate_sync = N'false',
@repl_freq = N'continuous',
@replicate_ddl = @repl_ddl,
@snapshot_in_defaultfolder = N'true',
@status = N'inactive', -- initialy publication is inactive / activated later after articles
are added to the pblication
@sync_method = N'concurrent' -- preferred
IF @@ERROR <> 0 RETURN
PRINT '2. Configureing publication ' + QUOTENAME('$(pub_name)') + ' on database ' + QUOTENAME('$(pub_dbname)') + ' ...'
EXEC sp_addpublication_snapshot
@publication = '$(pub_name)',
@frequency_type = 1,
@frequency_interval = 1,
@frequency_relative_interval = 1,
@frequency_recurrence_factor = 0,
@frequency_subday = 8,
@frequency_subday_interval = 1,
@active_start_time_of_day = 0,
@active_end_time_of_day = 235959,
@active_start_date = 0,
@active_end_date = 0,
@job_login = '$(repl_admin_account)',
@job_password = '$(repl_admin_password)',
@publisher_security_mode = 1, --Windows authentiction
@publisher_login = '$(repl_admin_account)',
@publisher_password = '$(repl_admin_password)'
IF @@ERROR <> 0 RETURN
PRINT 'Executing sp_helppublication for ' + QUOTENAME('$(pub_dbname)') + '.' + QUOTENAME('$(pub_name)') + ' ...'
EXEC sp_helppublication @publication = '$(pub_name)'
PRINT 'Executing sp_helppublication_snapshot for ' + QUOTENAME('$(pub_dbname)') + '.' + QUOTENAME('$(pub_name)') + ' ...'
EXEC sp_helppublication_snapshot @publication = '$(pub_name)'
--->>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>
-->>>>sp_addsubscription
USE [master]
GO
SQL Server Transactional Replication Related Scripts
Function: Register the (pull) subscription at the subscriber
-- TO DO: Parameters to set before executing this TSQL batch script
:SETVAR publisher_dbname TestDB
:SETvar publication_name TestDB-TranPub01
:SETVAR subs_server SUBSVR
:SETVAR subs_dbname TestDB
:SETVAR distributor DISTRIBSVR
:SETVAR repl_admin_account <domain>\<account_name
--replication admin account for non-prod environment
:SETVAR repl_admin_password <pwd>
--password for replication admin account
USE [$(publisher_dbname)]
SET NOCOUNT ON
IF db_name() IN ('master', 'model', 'msdb', 'tempdb', 'distribution', 'DBA')
BEGIN
RAISERROR('Please set the user database name properly and rerun the script', 15, 100)
RETURN
END
DECLARE @dynsql sysname
,@distibutor sysname
,@subscriber sysname
,@pub_dbname sysname
,@pub_name sysname
,@pub_login sysname
,@pub_password sysname
,@dest_dbname sysname
,@job_login sysname
,@job_password sysname
,@repl_ddl int
,@allow_initialize_from_backup varchar(5)
SET @pub_dbname = '$(publisher_dbname)'
SET @pub_name = '$(publication_name)'
SET @subscriber = '$(subs_server)'
SET @dest_dbname = '$(subs_dbname)'
SET @distibutor = '$(distributor)'
SET @job_login = '$(repl_admin_account)'
-- used by replication agents to connect
to publisher for queued updating subscriptions
-- make sure account has DBO access on subscriber
db
SET @job_password = '$(repl_admin_password)'
PRINT '1. Adding subscriber for pull subsctiption of publication ' + QUOTENAME(@pub_name) + ' on database ' + QUOTENAME(@pub_dbname) + ' ...'
EXEC sp_addsubscription
@publication = @pub_name,
@article = 'all',
@subscriber = @subscriber,
@destination_db = @dest_dbname,
@subscription_type = N'pull',
@update_mode = N'read only',
@sync_type = 'replication support only',
@status = 'active'
IF @@ERROR <> 0 RETURN
Execute sp_helpsubscription @publication = 'FTBTrade_TEST-TranPub01'
--@pub_name -
Equipment replication with new filter settings
Hi all,
ECC-CRM middleware settings are already in place. I then added status of the equipment as a new filter (Table-JEST, Field-STAT) as two lines (one for system status and one for user status) in R3AC1.
Delta replication is happening fine.
When i try to do initial load, no equipment is replciated for the filter settings maintained.
In R3AM1, i see the block size as zero.
Can someone help me on this?
Regards,
GowriHi Gowri,
Have you found any solution for this? We are also having same requirement, if you found any solution kindly share.
R3AC1 Question : How to add unallowed / non-standard filter settings?
I have implemented this logic but CRM_EQUI_DMBDOC is processing successfully. I need to restrict the equipment object based on status. please share if you got any solution.
Thanks,
Vijay -
Reinitializing only new tables in transactional replication
Hi,
I have to add one new table to an existing replication. I created table and added that table to the replication as well.Now I want to reinitialize only the new table rather than all the tables. Please anybody helpPublication properties immediate_sync and allow_anonymous need to be set to
false in order to only generate a snapshot for the newly added article(s).
I can add a new article and generate a snapshot for only the newly added article by executing the following:
USE TestDB1
GO
--Set allow_anonymous to false
EXEC sp_changepublication
@publication = 'TestTranPub1',
@property = N'allow_anonymous',
@value = 'false';
GO
--Set immediate_sync to false
EXEC sp_changepublication
@publication = 'TestTranPub1',
@property = N'immediate_sync',
@value = 'false';
GO
--Add new article
EXEC sp_addarticle
@publication = 'TestTranPub1',
@article = 'TestTable',
@source_object = 'TestTable',
@force_invalidate_snapshot = 1;
GO
--Add subscription to newly added article
EXEC sp_addsubscription
@publication = 'TestTranPub1',
@article = 'TestTable',
@subscriber = 'PACIFIC\SQL2012',
@destination_db = 'TestDB2',
@reserved = 'Internal';
GO
--Generate a new snapshot for only the newly added article
EXEC sp_startpublication_snapshot
@publication = 'TestTranPub1';
GO
Brandon Williams (blog |
linkedin)
Maybe you are looking for
-
When I am out for a run using earphone and a running APP I set my iphone 4 to shuffle songs but suddenly only 3-4 or 5-6 songs play and then they stop as if I set something to only play a certain number of songs from my playlist, its really irritatin
-
Leading ? xml version="1.0"? tag when creating / invoking web services
Hello friends. I'm wondering if anyone has any insight as to why I cannot create a fully formed XML document when developing a web service which includes the standard <? xml version="1.0" ?> leading tag. If I include the leading tag in my XML mapping
-
Linux - Can't move menu or enable menu bar button (like Windows)
I have used Firefox 4.0 betas on both Windows and Linux. I notice that unlike Windows, Linux doesn't seem to have the ability to hide the menu under the button which says 'Firefox'. I also cannot move the menu bar and place it on the navigation bar f
-
I want to set the initial value of a inputHidden field to a value in a request parameter but want it to set a property of my backing managed bean when submitted. The TLD says I cannot do something like this and I get an error: <h:inputHidden
-
Transferring ipod photos from ipod back to computer
Had to get new hard drive. Back ups were copromised. All 1100 photos from years are on ipod. Support says they cannot be transferred back to computer even thought music and videos transferred. Any ideas how i can save years worth of photos back to co