数据库表的建立

1.create database mydb6_product;

2.use mydb6_product;

3.mysql> create table employees(

-> id int(5) primary key,

-> name varchar(50) not null,

-> age int(10),

-> gender varchar(10) not null,

-> salary float(10,2)

-> );

4.mysql> create table orders(

-> id int(10) primary key,

-> name varchar(100) not null,

-> price float(10,2),

-> quantity int(10),

-> category char(50)

-> );

5.mysql> create table invoices(

-> order_id int ,

-> in_date date,

-> total_amount decimal(2,10) check (total_amount > 0),

-> foreign key (order_id) references orders(id)

-> );

相关推荐
菜鸟~noob2331 小时前
【电子战】第07篇:多普勒测向【含matlab代码】
android·开发语言·matlab
样子20182 小时前
Js 之根据白名单过滤 HTML(防止 XSS 攻击)
android·前端·javascript·html·xss
InsightCore2 小时前
别再往 Skill 里塞一切:我们如何重新思考 AI Debug Engineer
android·debug
Kapaseker2 小时前
写过 4000 行 ViewModel 后,我开始这样拆 Compose 页面
android·kotlin
恋猫de小郭2 小时前
ADB Wi-Fi 2.0 ,Android 17 把无线调试的连接链路重新做了一遍
android·前端·flutter
亿是守候 & 亿是承诺2 小时前
第二章 控制系统的数学模型
android
Carson带你学Android3 小时前
ADK for Kotlin:Google 官方 AI Agent 教程来了
android·agent·ai编程
一航jason14 小时前
Android平台推理框架及试用场景模型对比
android·人工智能·ai·架构·ai编程·llama
一航jason14 小时前
Android 端侧大模型推理框架对比
android·人工智能·ai·ai编程·llama·ai-native
新时代牛马15 小时前
cyclictest 毛刺从哪来?从ftrace、latencytop、perf到IRQ/调度延迟定位
android·开发语言·python·kotlin