Solved

Replication

Posted on 2011-09-07
5
259 Views
Last Modified: 2012-06-27
We are creating a replication, source and destination database structure is same but some of table names and column names are different. How to handle this situation.
thanks,
Ravi
0
Comment
Question by:asrithap
5 Comments
 
LVL 2

Expert Comment

by:maneksh
ID: 36502463
Hi

Assuming you are using sybase replication server . This can be handled in the replication defintion

When you create the replication definition in the source database you can define the replicate table name and replicate column name if the names are different

Please refer

http://infocenter.sybase.com/help/index.jsp?topic=/com.sybase.dc32410_1501/html/refman/X81836.htm

the option is

as replicate_column_name
    Specifies a column name in a replicate table into which data from the primary column will be copied. Use this clause when the source and destination columns have different names.


There are more ways to handle this using function strings if you need some manipulation of data as well

HTH

Maneksh

0
 
LVL 2

Expert Comment

by:maneksh
ID: 36502510
Sorry, I meant create replicaiton definition in the rep server ...

Thanks
Maneksh
0
 
LVL 4

Expert Comment

by:jlsilva01
ID: 36588142
You can do this creating replication definition.

Inside the REPDEF, you can say:

(PRIMARY) tabelaX.ColumnX will replicated into (REPLICATED) tabelaY.ColumnY

This way, you can solve your problem.
0
 
LVL 3

Accepted Solution

by:
pg_vinod earned 500 total points
ID: 36719813
Use:

for different table name destination database

with replicate table named

    Specifies the name of the table at the replicate database. table_name is a character string of up to 200 characters. table_owner is optional and represents the table owner. Data server operations may fail if the actual table owners do not correspond to what you specify in the replication definition.

    If you specify the replicate table name but do not also specify the primary table name, the replication definition name is assumed to be the name of the primary table.


for different columns at destination database

as replicate_column_name

    Specifies a column name in a replicate table into which data from the primary column will be copied. Use this clause when the source and destination columns have different names.
0
 

Author Closing Comment

by:asrithap
ID: 37080392
partial
0

Featured Post

Threat Intelligence Starter Resources

Integrating threat intelligence can be challenging, and not all companies are ready. These resources can help you build awareness and prepare for defense.

Join & Write a Comment

Is your company's data protection keeping pace with virtualization? Here are 7 dynamic ways to adapt to rapid breakthroughs in technology.
We have come a long way with backup and data protection — from backing up to floppies, external drives, CDs, Blu-ray, flash drives, SSD drives, and now to the cloud.
This video gives you a great overview about bandwidth monitoring with SNMP and WMI with our network monitoring solution PRTG Network Monitor (https://www.paessler.com/prtg). If you're looking for how to monitor bandwidth using netflow or packet s…
This video shows how to remove a single email address from the Outlook 2010 Auto Suggestion memory. NOTE: For Outlook 2016 and 2013 perform the exact same steps. Open a new email: Click the New email button in Outlook. Start typing the address: …

758 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now