zoukankan      html  css  js  c++  java
  • linux 查看数据库和表

    mysql -h localhost -u 用戶名 -p密碼                //連接數據庫
    use desk_show;                                          //使用數據庫
    show tables;                                              //顯示數據表
    describe desk6_0;                                     //顯示表結構

    mysql其他命令:

     

    show databases; 显示数据库

     

    create database name; 创建数据库

     

    use databasename; 选择数据库

      

    drop database name 直接删除数据库,不提醒

      

    show tables; 显示表

      

    describe tablename; 显示具体的表结构

    select 中加上distinct去除重复字段

     

    mysqladmin drop databasename 

    删除数据库前,有提示。

     

    显示当前mysql版本和当前日期

    select version(),current_date; 

  • 相关阅读:
    示波器测量电源的纹波
    hdoj 2717 Catch That Cow
    hdoj 1548 A strange lift
    hdoj 4586 Play the Dice
    zoj 2095 Divisor Summation
    hdoj 4704 Sum
    router-link传参
    字体自适应
    横向滚动div
    vue路由
  • 原文地址:https://www.cnblogs.com/cnteam/p/4091468.html
Copyright © 2011-2022 走看看