If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

 
Go Back  dBforums > General > Database Concepts & Design > database migration

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1 (permalink)  
Old 01-05-04, 01:49
shibby1011ph shibby1011ph is offline
Registered User
 
Join Date: Oct 2003
Location: Cebu City
Posts: 9
database migration

my problem involves migrating data from 2 databases but with different tables and fields. for example, database1 has a table named EMPLOYEES with a field named fname while database2 has a table named PERSONS with a field name firstName. i would like to transfer all info from EMPLOYEES.fname to PERSONS.firstName. is this possible with mysql?
Reply With Quote
  #2 (permalink)  
Old 01-05-04, 05:36
andrewst andrewst is offline
Moderator.
 
Join Date: Sep 2002
Location: UK
Posts: 5,171
Re: database migration

If you want a mySQL-specific answer you should ask the question in the mySQL forum. The generic answer is:

insert into persons(firstname, col1, col2, col3)
select fname, col4, col5, col6 from employees;
__________________
Tony Andrews
http://tinyurl.com/tonyandrews
Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On