This is a discussion on make a copy of database to local within the DB2 forums, part of the Database Server Software category; --> i am a db2 newbie. we have a server hosting a db2/6000 database that restricts the use of backup, ...
| |||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| ||||
| i am a db2 newbie. we have a server hosting a db2/6000 database that restricts the use of backup, generate ddl. i wonder if there is a simple way to transfer the database structure and data into my laptop, on which db2/nt was installed. i had tried to use DTS service from microsoft sql server. it didn't work. any suggestion? any help would be appreciated. alan. |
| |||
| If you have access to the database through the control center on your laptop, is there a "Generate DDL" option for the database? If so, you can use it to generate the DDL you are looking for. Data can be copied using: INSERT INTO local_table SELECT * FROM remote_table Good luck! Phil Sherman alanchinese wrote: > i am a db2 newbie. we have a server hosting a db2/6000 database that > restricts the use of backup, generate ddl. i wonder if there is a > simple way to transfer the database structure and data into my laptop, > on which db2/nt was installed. > i had tried to use DTS service from microsoft sql server. it didn't > work. > any suggestion? > any help would be appreciated. > alan. > |
| |||
| alanchinese wrote: > i am a db2 newbie. we have a server hosting a db2/6000 database that > restricts the use of backup, generate ddl. i wonder if there is a > simple way to transfer the database structure and data into my laptop, > on which db2/nt was installed. > i had tried to use DTS service from microsoft sql server. it didn't > work. > any suggestion? > any help would be appreciated. > alan. > You will need to use the db2move utility. Larry Edelstein |
| |||
| Correction: INSERT .... SELECT ...... won't work across databases. You should be able to export the data to your laptop then import it to a local table. If you can't export the data, then you could select it to a file and use that as input to load. You'll need to build delimiters or use fixed length output from the select. Watch out for long character and varchar columns if you try to use fixed length records - they can cause very large files. All of these options require you to "catalog" the remote database on your laptop. The "Generate DDL" option is accessed using a right-click on the database name in the control center's list of databases. Phil Sherman Phil Sherman wrote: > If you have access to the database through the control center on your > laptop, is there a "Generate DDL" option for the database? If so, you > can use it to generate the DDL you are looking for. > > Data can be copied using: > INSERT INTO local_table > SELECT * FROM remote_table > > Good luck! > > > Phil Sherman > > > > alanchinese wrote: > >> i am a db2 newbie. we have a server hosting a db2/6000 database that >> restricts the use of backup, generate ddl. i wonder if there is a >> simple way to transfer the database structure and data into my laptop, >> on which db2/nt was installed. >> i had tried to use DTS service from microsoft sql server. it didn't >> work. >> any suggestion? >> any help would be appreciated. >> alan. >> |
| |||
| "alanchinese" <alanchinese@yahoo.com> wrote in message news:1149109511.703890.81340@h76g2000cwa.googlegro ups.com... >i am a db2 newbie. we have a server hosting a db2/6000 database that > restricts the use of backup, generate ddl. i wonder if there is a > simple way to transfer the database structure and data into my laptop, > on which db2/nt was installed. > i had tried to use DTS service from microsoft sql server. it didn't > work. > any suggestion? > any help would be appreciated. > alan. > Have a look at the db2move command. It is documented in the Information Center; just enter the following in the Search box and click on the GO button: db2move -- Rhino |
| |||
| generate ddl is not allowed in control center. export a table is not working too. i tried db2move, it complains: SQL0551N "xxx" does not have the privilege to perform operation "BIND" on object "NULLID.DB2MOVE". SQLSTATE=42501 looking for bind file in current directory... bind file: DB2MOVE.BND .... could not be opened. actually, is db2move doing some sort of xml transferring from one database to another? Rhino wrote: > "alanchinese" <alanchinese@yahoo.com> wrote in message > news:1149109511.703890.81340@h76g2000cwa.googlegro ups.com... > >i am a db2 newbie. we have a server hosting a db2/6000 database that > > restricts the use of backup, generate ddl. i wonder if there is a > > simple way to transfer the database structure and data into my laptop, > > on which db2/nt was installed. > > i had tried to use DTS service from microsoft sql server. it didn't > > work. > > any suggestion? > > any help would be appreciated. > > alan. > > > Have a look at the db2move command. It is documented in the Information > Center; just enter the following in the Search box and click on the GO > button: db2move > > -- > Rhino |
| |||
| alanchinese wrote: > generate ddl is not allowed in control center. > export a table is not working too. > i tried db2move, it complains: SQL0551N "xxx" does not have the > privilege to perform operation "BIND" on object "NULLID.DB2MOVE". > SQLSTATE=42501 > looking for bind file in current directory... > bind file: DB2MOVE.BND .... could not be opened. > > actually, is db2move doing some sort of xml transferring from one > database to another? > > Rhino wrote: > >>"alanchinese" <alanchinese@yahoo.com> wrote in message >>news:1149109511.703890.81340@h76g2000cwa.googleg roups.com... >> >>>i am a db2 newbie. we have a server hosting a db2/6000 database that >>>restricts the use of backup, generate ddl. i wonder if there is a >>>simple way to transfer the database structure and data into my laptop, >>>on which db2/nt was installed. >>>i had tried to use DTS service from microsoft sql server. it didn't >>>work. >>>any suggestion? >>>any help would be appreciated. >>>alan. >>> >> >>Have a look at the db2move command. It is documented in the Information >>Center; just enter the following in the Search box and click on the GO >>button: db2move >> >>-- >>Rhino > > No ... it is using the db2look utility to generate the DDL and the export utility to move the data. Probably requires additional authorities. Best thing to do is to see your DBA. Larry Edelstein |
| |||
| DBA will not give me those access for just duplicating the database into my laptop. lol~ i am seeking an alternate way.... Larry wrote: > alanchinese wrote: > > > generate ddl is not allowed in control center. > > export a table is not working too. > > i tried db2move, it complains: SQL0551N "xxx" does not have the > > privilege to perform operation "BIND" on object "NULLID.DB2MOVE". > > SQLSTATE=42501 > > looking for bind file in current directory... > > bind file: DB2MOVE.BND .... could not be opened. > > > > actually, is db2move doing some sort of xml transferring from one > > database to another? > > > > Rhino wrote: > > > >>"alanchinese" <alanchinese@yahoo.com> wrote in message > >>news:1149109511.703890.81340@h76g2000cwa.googleg roups.com... > >> > >>>i am a db2 newbie. we have a server hosting a db2/6000 database that > >>>restricts the use of backup, generate ddl. i wonder if there is a > >>>simple way to transfer the database structure and data into my laptop, > >>>on which db2/nt was installed. > >>>i had tried to use DTS service from microsoft sql server. it didn't > >>>work. > >>>any suggestion? > >>>any help would be appreciated. > >>>alan. > >>> > >> > >>Have a look at the db2move command. It is documented in the Information > >>Center; just enter the following in the Search box and click on the GO > >>button: db2move > >> > >>-- > >>Rhino > > > > > No ... it is using the db2look utility to generate the DDL and the > export utility to move the data. Probably requires additional > authorities. Best thing to do is to see your DBA. > > Larry Edelstein |
| ||||
| It appears that you are atempting to make a copy of corporate data for your own (business?) needs. As long as you can read the data, this is possible but you have a number of non-database issues that need to be addressed: 1. Why does the data owner NOT want copies of the data made? 2. What laws apply to controlling access to the data? Which of them are likely to be broken when you have your own copy of the data? 3. What are your potential consequences to you and your employer of having the data on your laptop? Imagine that it's stolen and the data becomes available to the thief. Worse, what happens if you catch a virus that downloads the data to a nefarious individual? 4. Will you need to keep the data current? if so, how will you update it? When you update it, how much of your workday will it take? alanchinese wrote: > DBA will not give me those access for just duplicating the database > into my laptop. > lol~ > i am seeking an alternate way.... > > > Larry wrote: > >>alanchinese wrote: >> >> >>>generate ddl is not allowed in control center. >>>export a table is not working too. >>>i tried db2move, it complains: SQL0551N "xxx" does not have the >>>privilege to perform operation "BIND" on object "NULLID.DB2MOVE". >>>SQLSTATE=42501 >>>looking for bind file in current directory... >>>bind file: DB2MOVE.BND .... could not be opened. >>> >>>actually, is db2move doing some sort of xml transferring from one >>>database to another? >>> >>>Rhino wrote: >>> >>> >>>>"alanchinese" <alanchinese@yahoo.com> wrote in message >>>>news:1149109511.703890.81340@h76g2000cwa.googl egroups.com... >>>> >>>> >>>>>i am a db2 newbie. we have a server hosting a db2/6000 database that >>>>>restricts the use of backup, generate ddl. i wonder if there is a >>>>>simple way to transfer the database structure and data into my laptop, >>>>>on which db2/nt was installed. >>>>>i had tried to use DTS service from microsoft sql server. it didn't >>>>>work. >>>>>any suggestion? >>>>>any help would be appreciated. >>>>>alan. >>>>> >>>> >>>>Have a look at the db2move command. It is documented in the Information >>>>Center; just enter the following in the Search box and click on the GO >>>>button: db2move >>>> >>>>-- >>>>Rhino >>> >>> >>No ... it is using the db2look utility to generate the DDL and the >>export utility to move the data. Probably requires additional >>authorities. Best thing to do is to see your DBA. >> >>Larry Edelstein > > |