Log in
::
Register
::
Not logged in
Home
Tags
Articles
Editorials
Stairways
Forums
Scripts
Videos
Blogs
QotD
Books
Ask SSC
SQL Jobs
Training
Authors
About us
Contact us
Newsletters
Write for us
Recent Posts
Recent Posts
Popular Topics
Popular Topics
Home
Search
Members
Calendar
Who's On
Home
»
SQL Server 2008
»
T-SQL (SS2K8)
»
Trend Rolling Table
Trend Rolling Table
Rate Topic
Display Mode
Topic Options
Author
Message
Erin.
Erin.
Posted Thursday, December 06, 2012 9:52 AM
Ten Centuries
Group: General Forum Members
Last Login: Monday, April 29, 2013 11:43 AM
Points: 1,151,
Visits: 531
Development has created 7 day rolling tables on multiple servers. I want to pull this data over to another table so I can trend daily averages over a few months. The rolling table is populated throughout the day meaning data is added/removed every few minutes. What would be the best method to copy this data to my table without missing or creating duplicate rows?
Post #1393624
Erin.
Erin.
Posted Friday, December 07, 2012 6:50 PM
Ten Centuries
Group: General Forum Members
Last Login: Monday, April 29, 2013 11:43 AM
Points: 1,151,
Visits: 531
Debating on using replication or SSIS Lookup.
Post #1394292
Jeff Moden
Jeff Moden
Posted Friday, December 07, 2012 7:37 PM
SSC-Dedicated
Group: General Forum Members
Last Login: Today @ 11:05 AM
Points: 32,894,
Visits: 26,775
Erin-489205 (12/6/2012)
Development has created 7 day rolling tables on multiple servers. I want to pull this data over to another table so I can trend daily averages over a few months. The rolling table is populated throughout the day meaning data is added/removed every few minutes. What would be the best method to copy this data to my table without missing or creating duplicate rows?
Step 1 would be to find out how they are deleting the data so you can intercept it.
--Jeff Moden
"
RBAR
is pronounced "ree-bar" and is a "Modenism" for "
R
ow-
B
y-
A
gonizing-
R
ow".
First step towards the paradigm shift of writing Set Based code:
Stop thinking about what you want to do to a row... think, instead, of what you want to do to a column."
For better, quicker answers on T-SQL questions, click on the following...
http://www.sqlservercentral.com/articles/Best+Practices/61537/
For better answers on performance questions, click on the following...
http://www.sqlservercentral.com/articles/SQLServerCentral/66909/
Post #1394298
ScottPletcher
ScottPletcher
Posted Monday, December 10, 2012 4:17 PM
Ten Centuries
Group: General Forum Members
Last Login: Today @ 10:39 AM
Points: 1,318,
Visits: 1,765
Replication could be problematic as SQL will replicate the DELETEs as well as the INSERTs.
Also, do you need to capture UPDATE activity or just INSERTs?
Finally, are you on Enterprise or Standard Edition?
CDC could work well for this if you are on Ent Ed (unfortunately, CDC is not available on Std Ed).
SQL DBA,SQL Server MVP('07, '08, '09)
One man with courage makes a majority. Andrew Jackson
Post #1394811
Erin.
Erin.
Posted Tuesday, December 11, 2012 11:02 AM
Ten Centuries
Group: General Forum Members
Last Login: Monday, April 29, 2013 11:43 AM
Points: 1,151,
Visits: 531
SSIS lookup is working well.
Post #1395248
« Prev Topic
|
Next Topic »
Permissions
You
cannot
post new topics.
You
cannot
post topic replies.
You
cannot
post new polls.
You
cannot
post replies to polls.
You
cannot
edit your own topics.
You
cannot
delete your own topics.
You
cannot
edit other topics.
You
cannot
delete other topics.
You
cannot
edit your own posts.
You
cannot
edit other posts.
You
cannot
delete your own posts.
You
cannot
delete other posts.
You
cannot
post events.
You
cannot
edit your own events.
You
cannot
edit other events.
You
cannot
delete your own events.
You
cannot
delete other events.
You
cannot
send private messages.
You
cannot
send emails.
You
may
read topics.
You
cannot
rate topics.
You
cannot
vote within polls.
You
cannot
upload attachments.
You
may
download attachments.
You
cannot
post HTML code.
You
cannot
edit HTML code.
You
cannot
post IFCode.
You
cannot
post JavaScript.
You
cannot
post EmotIcons.
You
cannot
post or upload images.
Copyright © 2002-2013 Simple Talk Publishing. All Rights Reserved.
Privacy Policy.
Terms of Use.
Report Abuse.