SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


Refresh tables from production to Dev


Refresh tables from production to Dev

Author
Message
Robin35
Robin35
SSChasing Mays
SSChasing Mays (606 reputation)SSChasing Mays (606 reputation)SSChasing Mays (606 reputation)SSChasing Mays (606 reputation)SSChasing Mays (606 reputation)SSChasing Mays (606 reputation)SSChasing Mays (606 reputation)SSChasing Mays (606 reputation)

Group: General Forum Members
Points: 606 Visits: 1228
Hi,

I have a requirement to refresh some tables in dev from prod...and we need to do this every week...so i need to automate...

I thought of using SSIS, but never did it....if anyone did please let me know the process or your suggestions.

Thanks
sql-lover
sql-lover
SSCommitted
SSCommitted (1.6K reputation)SSCommitted (1.6K reputation)SSCommitted (1.6K reputation)SSCommitted (1.6K reputation)SSCommitted (1.6K reputation)SSCommitted (1.6K reputation)SSCommitted (1.6K reputation)SSCommitted (1.6K reputation)

Group: General Forum Members
Points: 1603 Visits: 1930
Robin35 (5/15/2013)
Hi,

I have a requirement to refresh some tables in dev from prod...and we need to do this every week...so i need to automate...

I thought of using SSIS, but never did it....if anyone did please let me know the process or your suggestions.

Thanks


When you mean refresh, you mean drop and recreate the whole table? Are you keeping some records, if that's the case, how many? ... how big the table is or will be? ...

SSIS maybe faster but also more difficult to maintain.

Depending of how many records and where those two instances are, you may consider bcp as well. You export via bcp, then import via bcp. You can put that logic inside a job and there you go, you have it scheduled.

If you need to wipe out the whole table, you can drop indexes prior import, truncate, and re-import. Take a look on dependencies though, like constraints or identity keys. That may be an issue when refreshing the table, even with SSIS.

If you go that route, here's a good link or article for bcp: https://www.simple-talk.com/sql/database-administration/working-with-the-bcp-command-line-utility/
arnipetursson
arnipetursson
Mr or Mrs. 500
Mr or Mrs. 500 (537 reputation)Mr or Mrs. 500 (537 reputation)Mr or Mrs. 500 (537 reputation)Mr or Mrs. 500 (537 reputation)Mr or Mrs. 500 (537 reputation)Mr or Mrs. 500 (537 reputation)Mr or Mrs. 500 (537 reputation)Mr or Mrs. 500 (537 reputation)

Group: General Forum Members
Points: 537 Visits: 1019
Do you intend to move all objects AND all data?
Do you have constraints on having prod data in DEV? (security etc.)

You may need processes that obfuscate data that cannot be viewed by developers.
Robin35
Robin35
SSChasing Mays
SSChasing Mays (606 reputation)SSChasing Mays (606 reputation)SSChasing Mays (606 reputation)SSChasing Mays (606 reputation)SSChasing Mays (606 reputation)SSChasing Mays (606 reputation)SSChasing Mays (606 reputation)SSChasing Mays (606 reputation)

Group: General Forum Members
Points: 606 Visits: 1228
Thanks for the response...

Never mind our requirement has changed and we are going to do full db restore...

Thanks again
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search