Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

Sql table replication, data insertion, field migration

2025-03-26 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Database >

Share

Shulou(Shulou.com)06/01 Report--

Migrate the field RegTime value to RegTime2: update commodity set RegTime2 = RegTimeTable commodities2 is pre-created, insert all the data in table commoditiesinto table commodities2: insert into commodities2 select * from commoditiesMigrate some fields in table commoditiesinto table commodities2: delete from commodities2; insert into commodity2 (commodityID,commodityName) select commodityID,commodityName from commoditySELECT INTO FROM statement, currently not supported in mysql, for example: select * into commodity3 from commodity1 So you can use the following method to create + data table migration in unsupported databases such as mysql: create table commodity5 as select * from commodity 2 create table commodity5 (select * from commodity2)

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Database

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report