1、# Oracle備份一張表
數(shù)據(jù)庫:myOnly
創(chuàng)建表:myTable 的備份表 myTable_tmpe
create table myTable_tmpe as select * from myTable ;
補充:
--在myTable 中添加一條學生的數(shù)據(jù) ;
insert into myTable (id, type, code, name, parent_code,sync_flag) values ('110', 'student', '01', '學生', '00','');
commit;
--刪除myTable 表原有數(shù)據(jù) ;
delete from myTable ;
commit;
參考 http://www.cnblogs.com/tanhuayixian/p/6589054.html
2、sqlserver
--DataTable 原數(shù)據(jù)表
--DataTable_20150717 要備份的新表名
select * into DataTable_20150717
from DataTable Where [條件1,條件2];
3、mysql
類似 oracle
http://jingyan.baidu.com/article/14bd256e49c26dbb6c26127d.html