sql - Can we create a table in MySQL from scratch using INTO without defining using CREATE before? -
i have next sql construct:
what tried todo extract info rbp table , straight-away creating new_table
insert new_table select pdb_id, chain_id rbp exp = "x-ray" , header = "rna binding protein/rna" but got this:
_mysql_exceptions.programmingerror: (1146, "table 'mydb.new_table' doesn't exist") is possible without performing before?
create table new_table ( pdb_id char(8) chain_id char(2) )
you can create virtual table (view) existed table follows:
create view view_name select column_name table_name ;
in case, can write
create view view_name select pdb_id, chain_id rbp exp = "x-ray" , header = "rna binding protein/rna";
mysql sql
No comments:
Post a Comment