Darren DICK
darrend at nimble.com.au
Tue Jan 31 06:18:32 CST 2006
Hi Jim et al I like your Select * INTO business Does it work with SQL? Anyway... I found a brilliant - and free SPROC to do it for us We wanted to create several new 'blank' SQL dbs using scripts from Original dB with about 450 tables The majority of the tables we only wanted the table structure so the standard EntManager script feature was fine BUT We wanted to populate our destination new 'blank' dB with data from a few tables from our Original as we went Not all - just a few - Because they are needed tables in each and every new 'blank' db but they have thousands of rows of data in 'em Didn't want to write Insert Field, field WITH value, value for each ROW of the needed tables This SPROC saved the day and is brilliantly easy to use No affiliation at all - here's the link - heaps of other stuff there as well http://vyaskn.tripod.com/code.htm#inserts Darren ------------------------------ T: 0424 696 433 -----Original Message----- From: dba-sqlserver-bounces at databaseadvisors.com [mailto:dba-sqlserver-bounces at databaseadvisors.com] On Behalf Of Jim Lawrence Sent: Tuesday, 31 January 2006 5:55 PM To: dba-sqlserver at databaseadvisors.com Subject: Re: [dba-SQLServer] Include data in Generate SQL Script Darren: I am not sure what you mean but you can transfer data by simply exporting it from one set of tables and importing it into another set of tables in the current db. ...or have you looked at the 'INTO' like: "SELECT * INTO MyRemoteTableName IN '\\server\databse\LocationOfMyRemoteMDB' from MyLocalTable;" Using this select in conjunction with an 'INSERT' sql can extract data from one MDB and place it into another. Syntax SELECT column_name(s) INTO newtable [IN externaldatabase] FROM source HTH Jim -----Original Message----- From: dba-sqlserver-bounces at databaseadvisors.com [mailto:dba-sqlserver-bounces at databaseadvisors.com] On Behalf Of Darren DICK Sent: January 30, 2006 5:08 PM To: dba-sqlserver at databaseadvisors.com Subject: [dba-SQLServer] Include data in Generate SQL Script Hi all When I use "Generate SQL script" to create a 'blank' dB of tables etc, is there an option, a tool (even 3rd party tool) that will allow me to say... Select certain tables in the original dB and to to have the data in those tables included in the "Generate SQL script"? Make sense? Many thanks Darren ----------------------------- _______________________________________________ dba-SQLServer mailing list dba-SQLServer at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/dba-sqlserver http://www.databaseadvisors.com _______________________________________________ dba-SQLServer mailing list dba-SQLServer at databaseadvisors.com http://databaseadvisors.com/mailman/listinfo/dba-sqlserver http://www.databaseadvisors.com