易截截图软件、单文件、免安装、纯绿色、仅160KB

oracle 对应的MySQL的语句

orcle 语句 create table book1(name, price) as select book_name, price form book;
对应的MySQL的语句是什么

create table book1 as select book_name, price form book; 这样在MySQL里可以,但是却不能改属性的名字。
SQL code:

create table book1 select book_name,price form book;



SQL code:

mysql> select * from t1;
+---+------+---------+
| a | f | message |
+---+------+---------+
| 1 | 1 | Testing |
| 2 | 2 | table |
| 3 | 3 | t1 |
+---+------+---------+
3 rows in set (0.11 sec)

mysql>

mysql> create table t4 as select a as id,f from t1;
Query OK, 3 rows affected (0.11 sec)
Records: 3 Duplicates: 0 Warnings: 0

mysql> select * from t4;
+----+------+
| id | f |
+----+------+
| 1 | 1 |
| 2 | 2 |
| 3 | 3 |
+----+------+
3 rows in set (0.00 sec)

mysql>


SQL code:
mysql> create table book1 as select name as testname from a;
Query OK, 6 rows affected (0.22 sec)
Records: 6 Duplicates: 0 Warnings: 0

mysql> select * from book1;
+----------+
| testname |
+----------+
| chen |
| chen |
| zhao


相关问答:

oracle sql developer 查询显示中文乱码

环境:1.win2003server+oracle9i
2.oracle9i字符集为AMERICAN_AMERICA.WE8ISO8859P1
3.oracle sql developer版本 1.5.5
现象描述: 1.在sql developer 中查询oracle中的某个表,中文全部显示为乱码。 ......

jsp备份mysql只有空文件

用jsp做东西给完全不懂mysql的人用,可是备份时只有空文件,这是什么情况,
最好有源代码,谢谢
其实备份的过程我想大概是这样的:
将表A中的数据放到ArrayList中,然后将这个ArrayList中的数据再存到表B中。 ......

C语言 Mysql 疑问

if(mysql_init(&mysql)==NULL)
{
sprintf(ErrMsg,"We are outof Memory");
return(false);
}

if(!mysql_real_connect(&mysql,"localhost","test" ......

MySQL数据包过大

我用一个循环往数据库里面存文件,本来可以作为文件存放数据库里面只放文件的位置的,但是没有办法租的服务器网页空间大小有限制数据库没有限制。语句是这样的


public static final DataBase.MAXSIZE=102 ......

MYSQL中根据字段值判断返回不同的值

在mysql中有一张表,有三个字段total,max, min,都是int型的值,可以写一个sql语句完成功能:
根据每条记录中,如果total>max,返回2,如果total <min返回1,如果都条件都不符合返回0。急求!!!!
mysql? ......
© 2009 ej38.com All Rights Reserved. 关于E健网联系我们 | 站点地图 | 赣ICP备09004571号