Solved

mysql  5.1 (or later) - is it possible to define IN THE DATABASE DEFINITION alternate names for tables and fields

Posted on 2014-11-11
2
129 Views
Last Modified: 2014-11-11
we have an inherited db that is being migrated in several phases.
it would be best to define a set of synonyms (aliases) so that the new names could be used in new queries/scripts
and then eventually usage of the old (awful conventions were used)  would be phased out.

is there a DEFINE (old_table_name, new_table_name)    feature somewhere?

i think the answer is no (i've not been able to find anything)
0
Comment
Question by:willsherwood
2 Comments
 
LVL 83

Accepted Solution

by:
Dave Baldwin earned 500 total points
ID: 40436457
I think the only thing you can do is copy the tables and rename the columns.
0
 

Author Closing Comment

by:willsherwood
ID: 40436484
thanks - saves me further time stewing over it!
0

Featured Post

Complete VMware vSphere® ESX(i) & Hyper-V Backup

Capture your entire system, including the host, with patented disk imaging integrated with VMware VADP / Microsoft VSS and RCT. RTOs is as low as 15 seconds with Acronis Active Restore™. You can enjoy unlimited P2V/V2V migrations from any source (even from a different hypervisor)

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Foreword This is an old article.  Instead of using the MySQL extension that was used in the original code examples, please choose one of the currently supported database extensions instead.  More information is available here: MySQLi / PDO (http://…
Popularity Can Be Measured Sometimes we deal with questions of popularity, and we need a way to collect opinions from our clients.  This article shows a simple teaching example of how we might elect a favorite color by letting our clients vote for …

820 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question