Showing posts with label application. Show all posts
Showing posts with label application. Show all posts

Friday, March 30, 2012

replication to sql server by activeX

Hello
i have a an application developed in vb6.0 and back end sql server 2000.
i have a batch file that i created to replicate the data from the sql server
2000 on my pc(local) to replicate on another sql server 2000 which is found
on another machine and the batch file is working fine.
i would like to implement it in my VB application.That is the user will
have a button on the program and on click this will do the replication that
is being done by the batch file for the moment.
i can call the batch file but we would like to do it by activeX.
Is there any activeX that already exist?
how can i do this by using activeX in VB6.0
If you need additional info please let me know..
Thx a lot
Nazeedah
try this:
http://www.indexserverfaq.com/replic...excontrols.zip
Hilary Cotter
Director of Text Mining and Database Strategy
RelevantNOISE.Com - Dedicated to mining blogs for business intelligence.
This posting is my own and doesn't necessarily represent RelevantNoise's
positions, strategies or opinions.
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
Looking for a FAQ on Indexing Services/SQL FTS
http://www.indexserverfaq.com
"Nazeedah" <Nazeedah@.discussions.microsoft.com> wrote in message
news:53D7A4A9-EBEB-4F76-AF9B-5EF670EBC707@.microsoft.com...
> Hello
> i have a an application developed in vb6.0 and back end sql server 2000.
> i have a batch file that i created to replicate the data from the sql
> server
> 2000 on my pc(local) to replicate on another sql server 2000 which is
> found
> on another machine and the batch file is working fine.
> i would like to implement it in my VB application.That is the user will
> have a button on the program and on click this will do the replication
> that
> is being done by the batch file for the moment.
> i can call the batch file but we would like to do it by activeX.
> Is there any activeX that already exist?
> how can i do this by using activeX in VB6.0
> If you need additional info please let me know..
> Thx a lot
> Nazeedah
>
|||hello
Thank you for the link. its very interesting but i am bit lost in all the
code. could you please tell me which one is more specific in my case
Thank you a lot
"Nazeedah" wrote:

> Hello
> i have a an application developed in vb6.0 and back end sql server 2000.
> i have a batch file that i created to replicate the data from the sql server
> 2000 on my pc(local) to replicate on another sql server 2000 which is found
> on another machine and the batch file is working fine.
> i would like to implement it in my VB application.That is the user will
> have a button on the program and on click this will do the replication that
> is being done by the batch file for the moment.
> i can call the batch file but we would like to do it by activeX.
> Is there any activeX that already exist?
> how can i do this by using activeX in VB6.0
> If you need additional info please let me know..
> Thx a lot
> Nazeedah
>
|||its code sample 5
Hilary Cotter
Director of Text Mining and Database Strategy
RelevantNOISE.Com - Dedicated to mining blogs for business intelligence.
This posting is my own and doesn't necessarily represent RelevantNoise's
positions, strategies or opinions.
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
Looking for a FAQ on Indexing Services/SQL FTS
http://www.indexserverfaq.com
"Nazeedah" <Nazeedah@.discussions.microsoft.com> wrote in message
news:BEC8AF2F-7EEB-4AF4-B269-7BDF5917BEA7@.microsoft.com...[vbcol=seagreen]
> hello
> Thank you for the link. its very interesting but i am bit lost in all the
> code. could you please tell me which one is more specific in my case
> Thank you a lot
> "Nazeedah" wrote:
sql

Replication to multiple subscribers question

We have an application that runs with MS SQL 2000 (SP3a) which is used for
tracking information from multiple sources. We are shortly going to be
setting up replication of this database with a secondary location, with a
third location planned by mid year. We know that there will be other
locations added over the course of the next few years. Our concern is that
if we have the snapshot expire, we will have to regenerate the snapshot and
reapply it to ALL subscribers before we can add a new subscriber. This is a
problem for 2 reasons. First because the foreign key relationships we have
between many of the tables appears to require that we delete the database on
the subscriber before we can apply the snapshot, and second because the
nature of our subscribers will mean that most of them will be disconnected
for long periods and as the number of subscribers grows it will be
increasingly unlikely that we will have them all connected at the same time.
It appears that our other option is to not have the snapshot expire, but MS
warns that this may cause performance problems but I haven't seen anything
that quantifies the potential performance problems.
Can anyone tell me what the "right" way of doing this is? What sort of
performance problems are we looking at if we don't have the snapshot expire?
Our database consists of approximately 100 or so user tables and currently
is about 300MB of data.
TIA
Ron L.
Ron,
I suspect the performance problems being talked about are proportional to
the amount of changes taking place to the data once the snapshot has been
made. EG if your snapshot contained static lookup tables, then having a
long-lived snapshot file wouldn't really be an issue. However if your
snapshot was of a productlisting table containing 1 million rows, and
product prices were changed on a regular basis (my case) then after
application of the snapshot you might find your merge agent (or distributor)
would struggle to send down the accumulated changes. BTW, in this case the
problem would be least for merge assuming records could be repeatedly
changed, and it avoids the issue of not being able to run the distribution
cleanup agent that you'll have.
HTH,
Paul Ibison
|||Paul
Thanks for the response. My data tends to be less changes and more
additions - we have logging records for text logs and records tracking
movement of parts within systems. At the moment, our largest table has just
over 100,000 records and the next largest is in the 20,000 record range.
One other option we were looking at was to have seperate publications
for each (or a small group of) additional server, thus making the snapshot
regeneration have less impact. Do you have any feeling as to whether this
is a better approach?
Thanks,
Ron L
"Paul Ibison" <Paul.Ibison@.Pygmalion.Com> wrote in message
news:%23FVkMhWLEHA.4052@.TK2MSFTNGP11.phx.gbl...
> Ron,
> I suspect the performance problems being talked about are proportional to
> the amount of changes taking place to the data once the snapshot has been
> made. EG if your snapshot contained static lookup tables, then having a
> long-lived snapshot file wouldn't really be an issue. However if your
> snapshot was of a productlisting table containing 1 million rows, and
> product prices were changed on a regular basis (my case) then after
> application of the snapshot you might find your merge agent (or
distributor)
> would struggle to send down the accumulated changes. BTW, in this case the
> problem would be least for merge assuming records could be repeatedly
> changed, and it avoids the issue of not being able to run the distribution
> cleanup agent that you'll have.
> HTH,
> Paul Ibison
>
|||Ron,
I agree that this approach leads to more granularity and therefore is more
versatile for your needs, As long as the publications are distinct units
then it should be OK - eg if there are PK-FK relationships across
publications then it's a no-go, so it depends how related the tables are.
Regards,
Paul
|||Paul
What we are thinking is multiple publications covering the same set of
tables. Is this not going to work?
Ron L
"Paul Ibison" <Paul.Ibison@.Pygmalion.Com> wrote in message
news:e454$eeLEHA.1484@.tk2msftngp13.phx.gbl...
> Ron,
> I agree that this approach leads to more granularity and therefore is more
> versatile for your needs, As long as the publications are distinct units
> then it should be OK - eg if there are PK-FK relationships across
> publications then it's a no-go, so it depends how related the tables are.
> Regards,
> Paul
>
|||Ron,
I've not heard of this arrangement before, but it sounds feasible with merge
replication.
I guess the only downside is increased maintenance.
Cheers,
Paul

replication Timestamp Field

Hi,
I like to know if i change the datatype from timestamp data type to binary(8) will it cause any interruption in application to run. And is there a way to replicate timestamp field to reporting databse without changing its datatype and data in timestamp field remains same
thx
DaveWell, since we don't know your application, and have no idea what kind of
events might cause "any interruption in application," your best bet is to
TRY IT in an isolated environment.
"dave" <anonymous@.discussions.microsoft.com> wrote in message
news:BD2EC7D2-4981-4455-B6FD-FC76B8780EFA@.microsoft.com...
> Hi,
> I like to know if i change the datatype from timestamp data type to
binary(8) will it cause any interruption in application to run. And is
there a way to replicate timestamp field to reporting databse without
changing its datatype and data in timestamp field remains same
> thx
> Dave|||Are you talking about changing it in the source (production) or the destination (report) server?
If source, then be very careful. Changing it will make it a "passive" binary(8). I.e., SQL Server
will not change the value for the row each time it is updated. And all your applications concurrency
mechanism will break down. This is assuming that the app actually uses the timestamp column for
concurrency.
--
Tibor Karaszi, SQL Server MVP
Archive at: http://groups.google.com/groups?oi=djq&as ugroup=microsoft.public.sqlserver
"dave" <anonymous@.discussions.microsoft.com> wrote in message
news:BD2EC7D2-4981-4455-B6FD-FC76B8780EFA@.microsoft.com...
> Hi,
> I like to know if i change the datatype from timestamp data type to binary(8) will it cause any
interruption in application to run. And is there a way to replicate timestamp field to reporting
databse without changing its datatype and data in timestamp field remains same
> thx
> Dave|||Yes Application does use it in aid to updating that table and that is on production server only.
i am talking about to change timestamp to binary on destination (Report ) server for transactional replication to work,
But temporarily just in case if production server fails then i need to change that binary(8) column to Timestamp and restore it on production server.
i did some test on pubs db. creating a Timaestamp and Binary column. so in the first screen shot
Name Test_Column_1_in_TS Test_Column_2_in_BIN
1) A 0x00000000000010E1 NULL
2) B 0x00000000000010E2 NULL
3) C 0x00000000000010E3 NULL
4) D 0x00000000000010E4 NULL
5) E 0x00000000000010E5 NULL
6) F 0x00000000000010E6 NULL
7) G 0x00000000000010E7 NULL
8) H 0x00000000000010E8 NULL
After Swapping the type of test columns 1 and 2 (similar scenario after setting up replication)
Name Test_Column_1_in_BIN Test_Column_2_in_TS
1) A 0x00000000000010E1 0x00000000000010E9
2) B 0x00000000000010E2 0x00000000000010EA
3) C 0x00000000000010E3 0x00000000000010EB
4) D 0x00000000000010E4 0x00000000000010EC
5) E 0x00000000000010E5 0x00000000000010ED
6) F 0x00000000000010E6 0x00000000000010EE
7) G 0x00000000000010E7 0x00000000000010EF
8) H 0x00000000000010E8 0x00000000000010F0
now considering the scenario of production server fails/unrecoverable so restoring from report server
after changing the data type
Name Test_Column_1_in_BIN Test_Column_2_in_TS
1) A 0x00000000000010F1 0x00000000000010E9
2) B 0x00000000000010F2 0x00000000000010EA
3) C 0x00000000000010F3 0x00000000000010EB
4) D 0x00000000000010F4 0x00000000000010EC
5) E 0x00000000000010F5 0x00000000000010ED
6) F 0x00000000000010F6 0x00000000000010EE
7) G 0x00000000000010F7 0x00000000000010EF
8) H 0x00000000000010F8 0x00000000000010F0
this is how values are changing. and it also reflects the transactional changes made in the rows. so i think value will change but it will maintain the order in which rows r being changed... do u guys agree'
thx
Dave

Wednesday, March 28, 2012

Replication Suggestions

I have an application with a sql backend. My company has an external
database on the webbox and an internal database for inter-company use. I
was given the job of replicating this database between external and internal.
I have 3 sql servers; BOX1 is external box that is used to run web frontend
and house the external backend of app, BOX2 is internal (conduit between
internal and external), BOX3 is another internal box that is used for backend
db of the internal frontend (hope this makes sense). BOX2 can only be a pull
subscription from BOX1 and somehow this has to repl to BOX3. This
application is a third party vendor app so I cannot modify the data
structure. I'm new to replication and I'm not sure what the best way to
accomplish this task. I tried transactional but I ran into a snag with 15 of
the 120 tables that do not have unique id's. Any ideas or suggestions
would be great.
Thanks in Advance,
rob
What you are trying to do is called republishing. Set up Box2 to be a
publisher to Box3. Set up Box1 to replicate to Box2. Make sure when you are
creating your articles you select the snapshot option, keep existing table
unchanged.
Regarding your problem with a lack of unique id's - I think you mean a lack
of Primary Keys. Examine the data to see if you can't put primary keys on
these tables - they are updating and deleting rows on these tables according
to some criteria used to uniquely identify them - if you can figure out what
this criteria is - make this your pk.
Hilary Cotter
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
Looking for a FAQ on Indexing Services/SQL FTS
http://www.indexserverfaq.com
"Rob" <Rob@.discussions.microsoft.com> wrote in message
news:C247C730-10DF-4ED1-8C2E-CA26AA593066@.microsoft.com...
>I have an application with a sql backend. My company has an external
> database on the webbox and an internal database for inter-company use. I
> was given the job of replicating this database between external and
> internal.
> I have 3 sql servers; BOX1 is external box that is used to run web
> frontend
> and house the external backend of app, BOX2 is internal (conduit between
> internal and external), BOX3 is another internal box that is used for
> backend
> db of the internal frontend (hope this makes sense). BOX2 can only be a
> pull
> subscription from BOX1 and somehow this has to repl to BOX3. This
> application is a third party vendor app so I cannot modify the data
> structure. I'm new to replication and I'm not sure what the best way to
> accomplish this task. I tried transactional but I ran into a snag with 15
> of
> the 120 tables that do not have unique id's. Any ideas or suggestions
> would be great.
> Thanks in Advance,
> rob
>
|||Like Hillary states, some refer this process as cascading from A to B, from
B to C. Works well as long as the transactions are all going in one
direction. With Regards to unique ids, you are probably refering to PKs.
Follw Hillary's advise.
"Hilary Cotter" <hilary.cotter@.gmail.com> wrote in message
news:uPWgfQCDGHA.1816@.TK2MSFTNGP11.phx.gbl...
> What you are trying to do is called republishing. Set up Box2 to be a
> publisher to Box3. Set up Box1 to replicate to Box2. Make sure when you
are
> creating your articles you select the snapshot option, keep existing table
> unchanged.
> Regarding your problem with a lack of unique id's - I think you mean a
lack
> of Primary Keys. Examine the data to see if you can't put primary keys on
> these tables - they are updating and deleting rows on these tables
according
> to some criteria used to uniquely identify them - if you can figure out
what[vbcol=seagreen]
> this criteria is - make this your pk.
> --
> Hilary Cotter
> Looking for a SQL Server replication book?
> http://www.nwsu.com/0974973602.html
> Looking for a FAQ on Indexing Services/SQL FTS
> http://www.indexserverfaq.com
> "Rob" <Rob@.discussions.microsoft.com> wrote in message
> news:C247C730-10DF-4ED1-8C2E-CA26AA593066@.microsoft.com...
I[vbcol=seagreen]
to[vbcol=seagreen]
15
>

Replication SQL Server 2005 <-> SQL Server 2005 Express

Hi,
I'm Roby Eisenbraun Martins. I'm a C++, VB, C# developer.
I'm developing a new application that requires work off-line from the
database.
I'm trying to work with SQL server 2005 replication, copying the data to
a SQL Express database ( .mdf ), work off-line and then merge back into the
publisher database.
But It is not working.
Where can I find more articles about it?
Thank you,
Roby Eisenbraun Martins
What error message are you getting? There is no SQL Server Agent with SQL
Server Express. You have to run your sync through windows synchronization
manager or at scheduler (Task Scheduler).
Hilary Cotter
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
Looking for a FAQ on Indexing Services/SQL FTS
http://www.indexserverfaq.com
"Roby Eisenbraun Martins" <RobyEisenbraunMartins@.discussions.microsoft.com >
wrote in message news:E6A10EA2-CEAE-4DB0-943D-99B76D287CE4@.microsoft.com...
> Hi,
> I'm Roby Eisenbraun Martins. I'm a C++, VB, C# developer.
> I'm developing a new application that requires work off-line from the
> database.
> I'm trying to work with SQL server 2005 replication, copying the data
> to
> a SQL Express database ( .mdf ), work off-line and then merge back into
> the
> publisher database.
> But It is not working.
> Where can I find more articles about it?
> Thank you,
> Roby Eisenbraun Martins
>
|||Hi Hilary,
Thank you for your help.
I can create the publication but when I try to create a subscriber for
that publication from a SQL Express database It doesn't work. It returns with
an error message "Cannot find Server".
I tried creating the subscriber using the SQL Management studio but I
cann't select the SQLEXPRESS server as a subscriber.
How can I make a .mdf file as a subscriber for my publication?
Thank you,
Roby Eisenbraun Martins
"Hilary Cotter" wrote:

> What error message are you getting? There is no SQL Server Agent with SQL
> Server Express. You have to run your sync through windows synchronization
> manager or at scheduler (Task Scheduler).
> --
> Hilary Cotter
> Looking for a SQL Server replication book?
> http://www.nwsu.com/0974973602.html
> Looking for a FAQ on Indexing Services/SQL FTS
> http://www.indexserverfaq.com
> "Roby Eisenbraun Martins" <RobyEisenbraunMartins@.discussions.microsoft.com >
> wrote in message news:E6A10EA2-CEAE-4DB0-943D-99B76D287CE4@.microsoft.com...
>
>
|||Here are a couple more items to check while trying to get your connectivity
to the remote SQL Express installation working...
By default SQL Server 2005 Express SKU will install with network protocols
disabled. If you want to use a tool external to your SQL Express
installation box to connect to it, then you need to enable the network
protocols. In the "SQL Server 2005" program folder from the start menu, you
should be able to find a "Configuration Tools" folder. In this folder launch
the "SQL Server Surface Area Configuration" tool. After connecting to the
SQL Express instance in the tool, look under "Database Services" and
configure the "Remote Connections option.
Another item to note is that by default in SQL Server 2005 Express SKU, the
default instance is SQLEXPRESS, not MSSQLSERVER. When you try to connect
remotely, you need to use the server name and instance name, i.e.
<ComputerName>\SQLEXPRESS
Tom
This posting is provided "AS IS" with no warranties, and confers no rights.
"Roby Eisenbraun Martins" wrote:
[vbcol=seagreen]
> Hi Hilary,
> Thank you for your help.
> I can create the publication but when I try to create a subscriber for
> that publication from a SQL Express database It doesn't work. It returns with
> an error message "Cannot find Server".
> I tried creating the subscriber using the SQL Management studio but I
> cann't select the SQLEXPRESS server as a subscriber.
> How can I make a .mdf file as a subscriber for my publication?
> Thank you,
> Roby Eisenbraun Martins
> "Hilary Cotter" wrote:

Monday, March 26, 2012

Replication scenario question...Merge or Transactional?

The situation I am faced with is we have a web application supported by a SQL
2000(sp4) database that resides on a limited bandwidth network. Our
distributed users are constantly complaining of "slow" response times. Our
local users have no such complaints. Some of our leadership has suggested
sending a SQL server/IIS server to the remote location and using some type of
replication to synchronize the data between these boxes. The requirements
are for minimal latency and concurrent updating of data. The leadership also
want this solution to be completely automated (little or no supervision of
the replication process) and as with everything we do they want it right away
(we're talking days, not weeks). I am very new to replication and have read
through the BOL section and am in the process of reading Hillary Cotter's
book. I am leaning toward an implementation of Merge Replication but I am
unsure if this is the right solution. Any advice or informed opinions would
be greatly appreciated.
There is no concurrent replication option ie each solution will have a degree
of latency. If you use merge then you can select from a variety of conflict
resolvers and easily work offline. This might be your best option. There are
alternatives - queued updating subscribers, immediate updating subscribers
and bidirectional transactional replication. Do you have BLOBS in the table?
Are the subscribers always connected? Should they be able to continue if not
connected? These questions will clarify and narrow down the options a bit.
Whichever option you select, don't rush - you'll need time to configure it in
a test environment to establish a set of protocols (change management, error
handling...) and to simply verify that it all works for your situation.
HTH,
Paul Ibison
"Dave Stokes" wrote:

> The situation I am faced with is we have a web application supported by a SQL
> 2000(sp4) database that resides on a limited bandwidth network. Our
> distributed users are constantly complaining of "slow" response times. Our
> local users have no such complaints. Some of our leadership has suggested
> sending a SQL server/IIS server to the remote location and using some type of
> replication to synchronize the data between these boxes. The requirements
> are for minimal latency and concurrent updating of data. The leadership also
> want this solution to be completely automated (little or no supervision of
> the replication process) and as with everything we do they want it right away
> (we're talking days, not weeks). I am very new to replication and have read
> through the BOL section and am in the process of reading Hillary Cotter's
> book. I am leaning toward an implementation of Merge Replication but I am
> unsure if this is the right solution. Any advice or informed opinions would
> be greatly appreciated.

Replication sample program

Hello i am new to SQL Replication.

I have a application in which Publisher node insert/update/delete in a SQL server data base on it's own node.

I have 3-4 different nodes which has SQL servers.

My reqirement is that when ever i insert/update/delete on the sql server in the publisher node, all the subscriber should insert/update/delete the same data in their respective data base.

so in short, all the publishers and subscribers should have same set of data. note that the subscribers are not doing any additional changes in their databases.


Also , at some point of time (when there is a fail over in the subscriber database), while restarting the subscriber database, i need to first synchronize all the data which were lost during down time with the publisher database and then onwards continue replication.
I will term this as startup synchronization step.


Can i use the SQL Transactional replication for this purpose? DO i need some other mechanism for startup synchronization step.

For example in the publisher i run this query,
Insert into customer(customerid,name,itemname) Values(20,'faith','speaker')

Once this query is executed on the publisher, i want to see that all the customer tables on the various subscribers node should have this record (20,'faith','speaker').

Is Replication is good approach or any thing else is suggested.


Can any body point to some sample tutorial or sample script to perform this kind of operation using Replication

Thanks a lot in adavance

Yes. Transactional replication is good enough to implement your scenario.

Whenever your data change happened on the publisher, subscriber will get the same change immediately (just default setting , continuous mode for both log reader and distribution agents). As for your "startup synchronization step", you can just resynchronize subscription, publisher present data will wrap up and load to subscriber through snapshot and distribution agent.

Here is transactional replication introduction in SQL Books On Line. It will also point you to implementation sample through UI and/or scripts.

ms-help://MS.SQLCC.v9/MS.SQLSVR.v9.en/rpldata9/html/3ca82fb9-81e6-4c3c-94b3-b15f852b18bd.htm

Thanks

|||

Hello, Thanks for the info, it was really useful.

I have an extra complexity involved in my application. That is I have more than one set of publishers which are redundant to overcome the fail over situation.

When a particular publisher goes down , all the subscribers which were connected to the this failed publisher node, should now switch to a new publisher(before starting the replication , this subscriber should synchronise it self with the new publisher).

all the publishers independently updating there databases from a redundant lagacy application. that means i don't need to implement redundancy of publishers using the Replication.

I just should be able to synchronise the subscriber with the new publisher, assuming that the new publisher has the latest data (It is same as the .

There on, i should replicate the data from the new publisher to the subscriber.

Please proveide some details on how to perform this mixed approach.

Thanks in advance for your valuable feed back.

Replication removal - sysarticles

I had replication on a SQL 7 box and then removed it. I think it was not properly removed as while doing an upgrade of an application that uses the database I got a message saying -
[Microsoft][ODBC SQL server Driver][SQL Server] length of text,ntext,image (179948) to be replicated exceeds configured maximum 65536 - 2147217887 Microsoft OLEDB Provider for ODBC Drivers.
I also notice that the sysarticles table has entries in it for the tables in the database.
How may i resolve this problem?
All help appriciated
set max_repl_size to a larger value and try again.
sp_configure 'max text repl size', 200000
"Rohans" <anonymous@.discussions.microsoft.com> wrote in message
news:90B8EDF5-4EA3-4608-B400-591369278080@.microsoft.com...
> I had replication on a SQL 7 box and then removed it. I think it was not
properly removed as while doing an upgrade of an application that uses the
database I got a message saying -
> [Microsoft][ODBC SQL server Driver][SQL Server] length of text,ntext,image
(179948) to be replicated exceeds configured maximum 65536 - 2147217887
Microsoft OLEDB Provider for ODBC Drivers.
> I also notice that the sysarticles table has entries in it for the tables
in the database.
> How may i resolve this problem?
> All help appriciated

Friday, March 23, 2012

Replication questions, using VB

Hi all,
I?ve just got a vb (6) application with source-code from a customer and
was asked to 'fine-tune' and enhance the thing. Oh well, you got to
make a living, don't you...
Anyway. The application uses SQL Server to store data. One SQL Server
(msde) is installed on their server (let's call this one master) and a
user has a desktop and a laptop on his desk.
On the server, a publication has been created. Merge replication,
continuously. The publication is set to expire after 60 days.
The desktop connects to the master. He doesn't have SQL installed.
The laptop also has Sql Sever installed (msde again). The VB app pulled
a subscription to a local database. The user does the daily work in
that local database and all changes are merged automatically. When the
user goes away from the office, he can make changes and the other
office users can make changes and all is merged happily when he returns
and plugs into the network again.
No rocket science here :-)
I do have a few questions about some things that aren't very clear to
me... I've already started to read some BOL, some VB samples, MSDN and
some other stuff about VB and SQL and replication but maybe someone has
a few tips and tricks or watch-outs on the following questions:
- When the laptop user synchronises on a day to day basis (like in the
above scenario), does the subscription ever reach the 'expired' state?
From what I've read, I assume it doesn't (since it is synchronised
almost every day).
- Is the subscription also updated to start counting again from the
last synch?
- Is there a way to find out (using VB6) when the last synchronisation
occurred? The application currently sets a date/time value in an INI
file when the user selects "pull subscription" in the application and
then warns the user that he needs to synchronise. The
warning-calculation is based on the initial subscription date and not
taking any synchronisations in account; explaining the question.
- When the subscription expires, I presume you can delete the local
database and pull a new one, but what when a user messes his local DB
beyond the limit. Can you make your local DB 'invalid'? I mean, I want
to connect to the network to pull a new subscription but as soon as I
connect it will start to merge this messed up data; how can I prevent
that?
Any comments appreciated,
Ferry
Your eyes are weary from staring at the CRT. You feel sleepy. Notice
how restful it is to watch the cursor blink. Close your eyes. The
opinions stated above are yours. When I snap my fingers, you cannot
imagine why you ever felt otherwise. <snap>
1) I won't expire unless the subscriber is offline for more than 60 days or
whatever your history retention period is (by default 2 days). So it
probably will expire if offline more than 2 days.
2) The subscription is generated every time the subscriber expires if you
have a named subscription or every time the snapshot agent runs if you have
an anonymous subscription.
3) if you are using the ActiveX control have a look at the status event. You
will have to trap this event for the sync complete message (IIRC), and then
set the time and date in the ini file.
4) When a merge agent runs, the merge agents merely syncs the changes that
occurred on the publisher and subscriber since the last merge agent ran. If
the user hoses his database you will probably want to do a full sync or a
reinitialization. If the user corrupts his database you would probably want
to drop the database and then recreate it and do a new sync.
The best way to check for corruption is by running a checkalloc. This will
detail system table corruption. The you would probably have to count objects
and do comparisons to determine what has been changed.
Tot zeins
Hilary Cotter
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
"Ferry" <ferryswi A@.T ferryswi D.O.T tmfweb D.O.T nl> wrote in message
news:mn.bd4c7d4cd875149f.23024@.TferryswiD.O.Ttmfwe bD.O.Tnl...
> Hi all,
> I?ve just got a vb (6) application with source-code from a customer and
> was asked to 'fine-tune' and enhance the thing. Oh well, you got to make a
> living, don't you...
> Anyway. The application uses SQL Server to store data. One SQL Server
> (msde) is installed on their server (let's call this one master) and a
> user has a desktop and a laptop on his desk.
> On the server, a publication has been created. Merge replication,
> continuously. The publication is set to expire after 60 days.
> The desktop connects to the master. He doesn't have SQL installed.
> The laptop also has Sql Sever installed (msde again). The VB app pulled a
> subscription to a local database. The user does the daily work in that
> local database and all changes are merged automatically. When the user
> goes away from the office, he can make changes and the other office users
> can make changes and all is merged happily when he returns and plugs into
> the network again.
> No rocket science here :-)
> I do have a few questions about some things that aren't very clear to
> me... I've already started to read some BOL, some VB samples, MSDN and
> some other stuff about VB and SQL and replication but maybe someone has a
> few tips and tricks or watch-outs on the following questions:
> - When the laptop user synchronises on a day to day basis (like in the
> above scenario), does the subscription ever reach the 'expired' state?
> From what I've read, I assume it doesn't (since it is synchronised almost
> every day).
> - Is the subscription also updated to start counting again from the last
> synch?
> - Is there a way to find out (using VB6) when the last synchronisation
> occurred? The application currently sets a date/time value in an INI file
> when the user selects "pull subscription" in the application and then
> warns the user that he needs to synchronise. The warning-calculation is
> based on the initial subscription date and not taking any synchronisations
> in account; explaining the question.
> - When the subscription expires, I presume you can delete the local
> database and pull a new one, but what when a user messes his local DB
> beyond the limit. Can you make your local DB 'invalid'? I mean, I want to
> connect to the network to pull a new subscription but as soon as I connect
> it will start to merge this messed up data; how can I prevent that?
>
> Any comments appreciated,
> Ferry
> --
> Your eyes are weary from staring at the CRT. You feel sleepy. Notice how
> restful it is to watch the cursor blink. Close your eyes. The opinions
> stated above are yours. When I snap my fingers, you cannot imagine why you
> ever felt otherwise. <snap>
>
|||Na rijp beraad schreef Hilary Cotter :
> 1) I won't expire unless the subscriber is offline for more than 60 days or
> whatever your history retention period is (by default 2 days). So it
> probably will expire if offline more than 2 days.
> 2) The subscription is generated every time the subscriber expires if you
> have a named subscription or every time the snapshot agent runs if you have
> an anonymous subscription.
> 3) if you are using the ActiveX control have a look at the status event. You
> will have to trap this event for the sync complete message (IIRC), and then
> set the time and date in the ini file.
> 4) When a merge agent runs, the merge agents merely syncs the changes that
> occurred on the publisher and subscriber since the last merge agent ran. If
> the user hoses his database you will probably want to do a full sync or a
> reinitialization. If the user corrupts his database you would probably want
> to drop the database and then recreate it and do a new sync.
> The best way to check for corruption is by running a checkalloc. This will
> detail system table corruption. The you would probably have to count objects
> and do comparisons to determine what has been changed.
> Tot zeins
>
> --
> Hilary Cotter
> Looking for a SQL Server replication book?
> http://www.nwsu.com/0974973602.html
> "Ferry" <ferryswi A@.T ferryswi D.O.T tmfweb D.O.T nl> wrote in message
> news:mn.bd4c7d4cd875149f.23024@.TferryswiD.O.Ttmfwe bD.O.Tnl...
<snap>
Thanks Hilary for the comments. I'll start looking into the details.
Have a nice Christmas,
Ferry
Your eyes are weary from staring at the CRT. You feel sleepy. Notice
how restful it is to watch the cursor blink. Close your eyes. The
opinions stated above are yours. When I snap my fingers, you cannot
imagine why you ever felt otherwise. <snap>
sql

Replication Question

I am trying to find a way to easily merge data from one development laptop to another.

Me and another developer are working on a .NET application that uses SQL 2k. Since we are the only two developers, and we both work from home, we spend a lot of time working remotely, so we each have a copy of SQL on our laptops. While this plan works fine for the most part, we are finding that keeping our systems synchronized to be more painful than one would think it should be. Initially, we tried just using DTS packages to copy tables and data from one system to the other, but this would cause one person's data they had to be lost (not a bad thing, but a real pain if you are testing a specific scenario and have to have the data setup a certain way).

We then tried using SQL merge replication, but since the tables are still in active development, modifying, adding, or changing tables is next to impossible (I did find the way to disable the replication temporarily and then re-enable it, but it takes too long just to add a column or something else simple). I would be fine with the replication scenario if someone could suggest a way to easily modify the table schemas with the replication enabled.

I am pretty sure there has to a simple way to do what we are doing, its just that neither of us are familiar with SQL enough to really see how to do it. Is there a way to syncronize each row's data before pushing new schema elements to other servers using DTS, or is there an easy way to enable the replication and still be able to have access to the table's schema?It sounds to me like you are describing Merge replication for existing tables, and a bit of DTS (then establishing a new merge publication for ongoing changes) for new tables.

-PatP|||Exactly. For the normal, day-to-day stuff that we do the merge replication is fine because we are connected over a network (VPN or local LAN), so that works beautifully, I would like to keep it if possible. The pain starts when I have to make an update to the tables or add a new table (which at this point in development is VERY frequent, at least one new table a week and slight modifications to all as time and testing goes along). Unfortunately, we do not have the luxury of working off a plan, so the tables tend to be rather "from the hip", which compounds this problem even more.

I suppose I am more accustomed to LDAP replication (I am learning SQL the hard way), which replicates the schema objects in addition to the data. I am looking for something along those lines, where the master (or in this case Publisher) not only defines the data objects to the subscribers, it defines the schema to be used. I don't see why it would be that much different in SQL.

If I could just get a nod in the right direction, or even a 'it would be possible to do it, but watch for this and that' I would be eternally grateful, this is driving me nuts.sql

Wednesday, March 21, 2012

Replication problem with SQL Mobile

Dear ppl,

I have a windows mobile 5.0 pocket PC application that performs replication between a Publihser (PC, SQL SERVER 2005), and subscriber (SQL MOBILE) on the pocket PC. The problem I am having is as follows

I created a bidirectional publication (SQL SERVER 2005). Then the pocket pc application subscribe to it (SQL Mobile). Pocket PC app add some records and then synchronise the data. Lets suppose the Pocket PC app adds 2 records on SQL Mobile in a table with primary key 2000 and 2001, which also reflected on the server after syncronisation.

Now for some reason I had to delete the publication and recreate it. My pocket PC resubscribed to the new publication, synchronise the data and get records 2000 and 2001 in SQL Mobile db. Now when the pocket Pc app tries to add a new record to it, it comes up with the error something like "duplicate values not allowed". What it is trying to do is, it is trying to add a new record with id 2000, which is already there in the table and therefore ending up throwing exception.

Can anyone please tell me what is the solution to this problem. Am i missing anything? Do i need to do something with configuring publication while recreating it after deleting it.

Regards
Nabeel Farid

Is this PK column an identity column on the table?

Or is the app generating the value 2000?

Can you subscriber to this publication on a different mobile database and try inserting there?

Monday, March 12, 2012

Replication Performance

Hi,
I made a vb.net application that create a subscriber and subscribe it to an
article that I have created.
Yesterday when I start this application it took 2 minutes to create the
subscriber and copy the database from the publisher to the subscriber
Today I start the same application but on another laptop for another
subscriber and after 55 minutes the process was not finish. I stop the
application and I delete all the objects that was create in the replication
for that new subscriber.
Because of that, users that use another application that queries the same
database
get a connection timeout.
Do you have any idea of where should I look to find the nature of the problem?
Thanks in advance!
Can you figure out at what part of the process does it stall? Creating the
database, connecting with the publisher/subscriber, deploying the snapshot?
Hilary Cotter
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
Looking for a FAQ on Indexing Services/SQL FTS
http://www.indexserverfaq.com
"GC" <GC@.discussions.microsoft.com> wrote in message
news:D747B6EE-9078-4FC6-8CF5-ABCB148164ED@.microsoft.com...
> Hi,
> I made a vb.net application that create a subscriber and subscribe it to
> an
> article that I have created.
> Yesterday when I start this application it took 2 minutes to create the
> subscriber and copy the database from the publisher to the subscriber
> Today I start the same application but on another laptop for another
> subscriber and after 55 minutes the process was not finish. I stop the
> application and I delete all the objects that was create in the
> replication
> for that new subscriber.
> Because of that, users that use another application that queries the same
> database
> get a connection timeout.
> Do you have any idea of where should I look to find the nature of the
> problem?
> Thanks in advance!
|||sp_who2
Find out who is generating a block.
Mike
http://www.solidqualitylearning.com
Disclaimer: This communication is an original work and represents my sole
views on the subject. It does not represent the views of any other person
or entity either by inference or direct reference.
"GC" <GC@.discussions.microsoft.com> wrote in message
news:D747B6EE-9078-4FC6-8CF5-ABCB148164ED@.microsoft.com...
> Hi,
> I made a vb.net application that create a subscriber and subscribe it to
> an
> article that I have created.
> Yesterday when I start this application it took 2 minutes to create the
> subscriber and copy the database from the publisher to the subscriber
> Today I start the same application but on another laptop for another
> subscriber and after 55 minutes the process was not finish. I stop the
> application and I delete all the objects that was create in the
> replication
> for that new subscriber.
> Because of that, users that use another application that queries the same
> database
> get a connection timeout.
> Do you have any idea of where should I look to find the nature of the
> problem?
> Thanks in advance!
|||The Process is not stall, there still activity.
When I go on the subscription of the subscriber I can see that the
subscription is running. If I do a refresh I can see that some row are
download to the subscriber
because the amount of rows that are downloaded differ each time I do a refresh
May be my problem is the way I create my Articles.
I am a beginner in replication so I dont expect to have the best strategie
the first time.
By the way I want to thank you for all the support that you do to all of us
It is appreciated.
"Hilary Cotter" wrote:

> Can you figure out at what part of the process does it stall? Creating the
> database, connecting with the publisher/subscriber, deploying the snapshot?
> --
> Hilary Cotter
> Looking for a SQL Server replication book?
> http://www.nwsu.com/0974973602.html
> Looking for a FAQ on Indexing Services/SQL FTS
> http://www.indexserverfaq.com
> "GC" <GC@.discussions.microsoft.com> wrote in message
> news:D747B6EE-9078-4FC6-8CF5-ABCB148164ED@.microsoft.com...
>
>

Replication over VPN

I have a Delphi application that connects to SQL server 2K.

Recently another part of the company wanted to use the application, but the connection between us goes through a number of firewalls. The only solution that I have been able to come up with so far is for the new users to VPN into the server to use the application, but this is a real pain for them.

Is there an obvious alternative? No 're-write as a web app' please!

I have thought about setting the remote users up with a separatae server and then merge replicating betwen the two, but that would require a VPN connection to allow the replication to work (I presume). How would that work? What would open the VPN connection and close it after the replication was complete? What would happen to users that were connected at both the main server and the remote one when the VPN link was started?

Any thoughts gratefully received....Merge replication may require a complete redesign, unless your current design meets its requirements.|||Does the other division need both read and write access to the database? If not, you could transfer backups by sneakernet if nothing else.

Otherwise, talk to your network admins. It's their job to provide access through the firewalls for legitimate traffic. Better yet, get the head of the other division to expedite it.

Replication over satelite connection.

Hi everybody, we are designing an application for ships, and I want to replicate data between the ships and a home office. TCP/IP communication is not possible, but we have a e-mail based system for transferring files.
What is the best solution? Is it possible to have the publisher/subscriber to leave a file, and then let the e-mail system transfer the file and then later the subscriber/publisher can pick up the file and do the merge?
Any ideas?
Thanx, Kjetil
Kjetil,
this is not directly possible in the replication setup. You might want to
use DTS to import the file into a database then in the DTS package. Setup
replication between this staging database and your central system and you
can initiate replication locally.
HTH,
Paul Ibison
|||Thanks, this is what I tried to say to my boss. But how can this be implemented? Should I use merge replication or transactional replication.
In my home office, I will need a 'copy' of the ship database, in the first stage 9 ships.
Is it possible to block the database in the ships for updates while the replication process is running?
Or should I use transactional replication, will I then need a 'proxy database' at each ship and one for each ship in the home office. Is it possible to implement conflict resolution methods that guarantee the same result at all sites always?
The amount of data over the satellite link (64k) is an issue, so it is important to send only the changes.
Do you think I'm on track? Is it possible to implement.
Kjetil
|||Kjso,
as you need inserts updates and deletes to be replicated over the internet,
you are essentially coding what MS developers may well be creating in SQL
2005 :-). This is not straightforward at all (to say the least). You might
want to use triggers on each table which write an audit of changes to your
audit table(s). These audit table changes are then sent over the link to a
central server where they are applied to the central database. In my opinion
this is only going to be feasible at the central server if you have
partitioned data; dealing with conflicts will make this too difficult. Then
sending only the changes required back to the other subscribers is not
simple. You say that you want only changes, but a 'snapshot' would be more
straightforward.
HTH,
Paul Ibison

Replication over Replication...

Hi all.

I have created two replications. One from the main server (ERP) to my Mobile Manager Application (MMA) and the other one is from the MMA to all Mobile Devices (Tablet PCs). The last replication works fine (MMA => MD). But when the first replication (ERP => MMA) tries to update the tables (which are the same on both replications) I get the error that the first table to update cannot be updated because it is included in a replication.

I'm not that much experienced working with replication, so I'm looking for some answers to try to solve this problem. Maybe there are some other methods to work this issue.

I'd really appreciate any help or suggestions to work this around.

Thanks.

Fabio.

Fabio,

It would help if you can provide more details. For example, do you use transactional replication (readonly or updatable?) between ERP and MMA and merge replication between MMA and MD? And what is the exact error message your are seeing? What are you trying to do when the error happens (like a DML update or running replication agent etc). Plus the version and edition of SQL Server on each machine.

Thanks,

Zhiqiang Feng

|||Make sure you setup ERP to MMA first and then setup MMA to MD.|||

Thanks Zhiqiang for your reply.

In order to give you a better vision of this issue I have to say that:

1. Things are configured exactly as you said (ERP => MMA - Transactional (but Readonly) it only updates MMA, and MMA => MD - Merge Replication).

2. I configured first the ERP => MMA Replication, create my initial snapshot and the propagate it to MMA. After that created my MMA => MD replication and followed the previous steps detailed before.

3. Everything works fine between MMA => MD publication and subscriptions.

4. SQL Sever versions for ERP and MMA are 2000 SP4 and MD are MSDE SP3a.

My problem issues when ERP => MMA replication tries to update the data at MMA Database. It seems to try to modify some tables on the MMA Server, which I don't understand because it is supposed to be done when propagating the initial snapshot. Another thing I didn't say (sorry for that) is that I have this 2 replications because my customer doesn't want to expose his main server to the internet.

On the MMA machine I control some data like orders approval, customer payments and deposits procedures.

Thanks again for the help. I appreciate so much.

Fabio

|||

Fabio,

I was trying to setup a test environment to simulate what you described, will update my findings with you once I have some results. By the way, what's the exact error message your re seeing? error number, description etc?

Thanks,

Zhiqiang Feng

|||

Hi Zhiqiang.

I have found the answer for my problem. Thanks a lot for your interest in helping me.

In this link: http://www.replicationanswers.com/Republishing2005.asp I found exactly what I was looking for.

It may help others which have the same case.

Thanks again. I really appreciate your effort.

Fabio.

|||

Glad to hear that problem got solved!

Thanks,

Zhiqiang Feng

replication OS Errror 5

I'm using SQLDistribution.SQLDistribution.2 Active X
within a PowerBuilder App. The pull subscribers intitiate
replication from the application. Both publishers and
subscribers are MSDE SQL 2000.
I get: The process could not read file 'bla
bla'\snapshot.pre' due to OS error 5 - UNLESS the user
login running the application has been specifically
granted full control on the snapshot share folder. The
snapshot folder is a public share, not an administrative
share.
It is not a realistic solution for me to grant every user
full control over the share folder. I thought by
using "Impersonate SQL Server Agent Account" for the
subscribcriptions, that the subscribing servers startup
login account would be used to access the snapshot share
folder but apparently not?
Is there someway to use the replication activex but avoid
having to grant every application user full control of the
snapshot folder?
Thanks,
Pat
the minimum security on the files and folders is read and list folder and
contents. The minimum share permission required is read. Is the allow
inheritable permissions from parent to propagate to this object checked?
Are you sure that the account you are using has both of these rights on the
snapshot share and underlying files and folders?
You are correct when you select the impersonate option on a pull
subscription the SQL Server agent account on the Subscriber must have rights
to access the snapshot folder.
Hilary Cotter
Looking for a book on SQL Server replication?
http://www.nwsu.com/0974973602.html
"Pat" <anonymous@.discussions.microsoft.com> wrote in message
news:47f001c4734c$19e2cfe0$a501280a@.phx.gbl...
> I'm using SQLDistribution.SQLDistribution.2 Active X
> within a PowerBuilder App. The pull subscribers intitiate
> replication from the application. Both publishers and
> subscribers are MSDE SQL 2000.
> I get: The process could not read file 'bla
> bla'\snapshot.pre' due to OS error 5 - UNLESS the user
> login running the application has been specifically
> granted full control on the snapshot share folder. The
> snapshot folder is a public share, not an administrative
> share.
> It is not a realistic solution for me to grant every user
> full control over the share folder. I thought by
> using "Impersonate SQL Server Agent Account" for the
> subscribcriptions, that the subscribing servers startup
> login account would be used to access the snapshot share
> folder but apparently not?
> Is there someway to use the replication activex but avoid
> having to grant every application user full control of the
> snapshot folder?
> Thanks,
> Pat

Replication or Update via Trigger ?

Hi SQL Gurus,
I have an application where the end user insist that there should be nine(9)
databases, same server within the system.
There are 'shared tables' on one of the database where any
insert/update/delete on those 'shared tables' must appear immediately on
other databases.
In this case, should I use replication or doing updates via Trigger ?
Thanks for your comments,
KristI am not sure why he/she is insisting for identical databases? Perhaps,
instead of creating tables in all these databases, you can opt to create
views which simply SELECT from a table in a single a database. You don't
have to worry about the data being in sync either.
Replication is not a solution for addressing such requirements. You can opt
for a trigger, but with the information from your post, I rather would
conclude it is an overkill to support redundant data for no apparent
reasons.
--
- Anith
( Please reply to newsgroups only )|||Hi Anith,
I used to think of View.
But I need to create FK from transaction table to these 'shared tables'
e.g : SalesOrder must have FK to Salesman and Area table, where Salesman
and Area are 'shared tables'
How can I do this with view ?
Thanks,
Krist
"Anith Sen" <anith@.bizdatasolutions.com> wrote in message
news:#uM6uAfxDHA.1680@.TK2MSFTNGP12.phx.gbl...
> I am not sure why he/she is insisting for identical databases? Perhaps,
> instead of creating tables in all these databases, you can opt to create
> views which simply SELECT from a table in a single a database. You don't
> have to worry about the data being in sync either.
> Replication is not a solution for addressing such requirements. You can
opt
> for a trigger, but with the information from your post, I rather would
> conclude it is an overkill to support redundant data for no apparent
> reasons.
> --
> - Anith
> ( Please reply to newsgroups only )
>|||Krist, first find out the reason that your user needs 9 databases.
1. If is for security then perhaps create 9 different users or roles instead
and assign permissions accordingly.
2. If it's a limitation in the front end application then perhaps you'll
need to stick with several databases
3. If the user later wants to distribute the 9 databases to 9 different
servers then cross-database views become more tricky.
It's a rather strange requirement, and the underlying reason for it probably
constrains your options even further.
"tristant" <krislioe@.cbn.net.id> wrote in message
news:eAJAYgfxDHA.4064@.tk2msftngp13.phx.gbl...
> Hi Anith,
> I used to think of View.
> But I need to create FK from transaction table to these 'shared tables'
> e.g : SalesOrder must have FK to Salesman and Area table, where Salesman
> and Area are 'shared tables'
> How can I do this with view ?
> Thanks,
> Krist
> "Anith Sen" <anith@.bizdatasolutions.com> wrote in message
> news:#uM6uAfxDHA.1680@.TK2MSFTNGP12.phx.gbl...
> > I am not sure why he/she is insisting for identical databases? Perhaps,
> > instead of creating tables in all these databases, you can opt to create
> > views which simply SELECT from a table in a single a database. You don't
> > have to worry about the data being in sync either.
> >
> > Replication is not a solution for addressing such requirements. You can
> opt
> > for a trigger, but with the information from your post, I rather would
> > conclude it is an overkill to support redundant data for no apparent
> > reasons.
> >
> > --
> > - Anith
> > ( Please reply to newsgroups only )
> >
> >
>|||Hi Anthony,
You are absolutely right : the reason the number (3)
> 3. If the user later wants to distribute the 9 databases to 9 different
> servers then cross-database views become more tricky.
So, that is my reason, what options do I have now ?
Thanks,
Krist
"Anthony Faull" <anthony.faull@.NOSPAMsanlam.co.za> wrote in message
news:egFyt5fxDHA.536@.tk2msftngp13.phx.gbl...
> Krist, first find out the reason that your user needs 9 databases.
> 1. If is for security then perhaps create 9 different users or roles
instead
> and assign permissions accordingly.
> 2. If it's a limitation in the front end application then perhaps you'll
> need to stick with several databases
> 3. If the user later wants to distribute the 9 databases to 9 different
> servers then cross-database views become more tricky.
> It's a rather strange requirement, and the underlying reason for it
probably
> constrains your options even further.
> "tristant" <krislioe@.cbn.net.id> wrote in message
> news:eAJAYgfxDHA.4064@.tk2msftngp13.phx.gbl...
> > Hi Anith,
> > I used to think of View.
> > But I need to create FK from transaction table to these 'shared tables'
> > e.g : SalesOrder must have FK to Salesman and Area table, where
Salesman
> > and Area are 'shared tables'
> >
> > How can I do this with view ?
> >
> > Thanks,
> > Krist
> >
> > "Anith Sen" <anith@.bizdatasolutions.com> wrote in message
> > news:#uM6uAfxDHA.1680@.TK2MSFTNGP12.phx.gbl...
> > > I am not sure why he/she is insisting for identical databases?
Perhaps,
> > > instead of creating tables in all these databases, you can opt to
create
> > > views which simply SELECT from a table in a single a database. You
don't
> > > have to worry about the data being in sync either.
> > >
> > > Replication is not a solution for addressing such requirements. You
can
> > opt
> > > for a trigger, but with the information from your post, I rather would
> > > conclude it is an overkill to support redundant data for no apparent
> > > reasons.
> > >
> > > --
> > > - Anith
> > > ( Please reply to newsgroups only )
> > >
> > >
> >
> >
>|||Your options:
1. Partitioned views
2. Replication
3. Log shipping (backup & restore)
"tristant" <krislioe@.cbn.net.id> wrote in message
news:OQxaWDgxDHA.1760@.TK2MSFTNGP10.phx.gbl...
> Hi Anthony,
> You are absolutely right : the reason the number (3)
> > 3. If the user later wants to distribute the 9 databases to 9 different
> > servers then cross-database views become more tricky.
> So, that is my reason, what options do I have now ?
> Thanks,
> Krist
> "Anthony Faull" <anthony.faull@.NOSPAMsanlam.co.za> wrote in message
> news:egFyt5fxDHA.536@.tk2msftngp13.phx.gbl...
> > Krist, first find out the reason that your user needs 9 databases.
> > 1. If is for security then perhaps create 9 different users or roles
> instead
> > and assign permissions accordingly.
> > 2. If it's a limitation in the front end application then perhaps you'll
> > need to stick with several databases
> > 3. If the user later wants to distribute the 9 databases to 9 different
> > servers then cross-database views become more tricky.
> >
> > It's a rather strange requirement, and the underlying reason for it
> probably
> > constrains your options even further.
> >
> > "tristant" <krislioe@.cbn.net.id> wrote in message
> > news:eAJAYgfxDHA.4064@.tk2msftngp13.phx.gbl...
> > > Hi Anith,
> > > I used to think of View.
> > > But I need to create FK from transaction table to these 'shared
tables'
> > > e.g : SalesOrder must have FK to Salesman and Area table, where
> Salesman
> > > and Area are 'shared tables'
> > >
> > > How can I do this with view ?
> > >
> > > Thanks,
> > > Krist
> > >
> > > "Anith Sen" <anith@.bizdatasolutions.com> wrote in message
> > > news:#uM6uAfxDHA.1680@.TK2MSFTNGP12.phx.gbl...
> > > > I am not sure why he/she is insisting for identical databases?
> Perhaps,
> > > > instead of creating tables in all these databases, you can opt to
> create
> > > > views which simply SELECT from a table in a single a database. You
> don't
> > > > have to worry about the data being in sync either.
> > > >
> > > > Replication is not a solution for addressing such requirements. You
> can
> > > opt
> > > > for a trigger, but with the information from your post, I rather
would
> > > > conclude it is an overkill to support redundant data for no apparent
> > > > reasons.
> > > >
> > > > --
> > > > - Anith
> > > > ( Please reply to newsgroups only )
> > > >
> > > >
> > >
> > >
> >
> >
>

Replication on wireless networks - Urgent

I have an application that uses SQL Server merge replication. This application uses a settings.ini file to connect to the server/publisher. This file contains the publisher name, publisher database name, subscriber name, subscriber database name and conne
ction string.
This application works fine over the LAN and even WLAN. I want the application to identify the publisher from a server that's on the internet and my subscriber will be a mobile node. The problem is when I put the publisher in a public network, my subscrib
er doesnot recogonise it. I tried giving the IP address of the publisher along with the publisher name in the ini file. But this doesn't work. I do not have the source code of the application and hence cannot do anything inside the application to make it
recogonise the publisher.
Is there a solution for this? Please help.
Rammy,
hopefully using an Alias for the IP address will do it. Also you'll need to
consider the permissions and if you are using Windows authentication for the
agents, then this'll need to be of the pass-through variety. Here is an
article I used to set up VPN access:
http://support.microsoft.com/?id=321822
HTH,
Paul Ibison

Friday, March 9, 2012

replication on demand

Hi,
I am writing C# application accessing 2 databases. One them is publisher
and replicates two of its tables to the other (transactional replication). I
know that replication can either be immediate or scheduled, but is there any
way to perform replication on demand (from my c# app), for instance
executing some sql statement?!
Piotrek
have a look at the initialize and run methods using the activeX controls.
Hilary Cotter
Looking for a book on SQL Server replication?
http://www.nwsu.com/0974973602.html
"Piotrek Stachowicz" <dynamite@.poczta.onet.pl> wrote in message
news:cdlqsg$r30$1@.news.onet.pl...
> Hi,
> I am writing C# application accessing 2 databases. One them is
publisher
> and replicates two of its tables to the other (transactional replication).
I
> know that replication can either be immediate or scheduled, but is there
any
> way to perform replication on demand (from my c# app), for instance
> executing some sql statement?!
> Piotrek
>
|||Hi,

> have a look at the initialize and run methods using the activeX
controls.
Could you be a slightly more specific (some msdn reference perhaps?). I'm
new to the topic, and I am not quite sure what you mean.
Thanks,
Piotrek
|||here is a code sample of what I am talking about
http://support.microsoft.com/default...&Product=sql2k
For more info on the actual methods have a look at
http://msdn.microsoft.com/library/de...bjcol_00j8.asp
Hilary Cotter
Looking for a book on SQL Server replication?
http://www.nwsu.com/0974973602.html
"Piotrek Stachowicz" <dynamite@.poczta.onet.pl> wrote in message
news:cdnrb9$t9f$1@.news.onet.pl...
> Hi,
> controls.
> Could you be a slightly more specific (some msdn reference perhaps?). I'm
> new to the topic, and I am not quite sure what you mean.
> Thanks,
> Piotrek
>
>

Replication of DB2 data on SQL Server

What tools are available to update SQL Server application tables from a DB2 database?
The DB2 database is on iSeries (AS/400).
Thanks in advance.you can probably create a linked server from SQL Server to DB2 and then use select statements as usual. search for db2 on the link below.

http://msdn2.microsoft.com/en-us/library/ms190479.aspx|||It really depends on the version of SQL Server you are running. Linked servers as mentioned is one option, another option is using DTS or SSIS to transfer data regulary. Unfortunately it appears that you have to pull the data from the SQL Server, I don't think the AS/400 will be able to push data to the SQL Server.|||You could write java programs to push data either way using an JDBC connectivity.

We can also look @. tools from IBM to push data to SQL Server using DB2 Information Integrator V8, IBM DB2 Replication & DataPropagator.