当前位置:网站首页>Database answers build standard, answer as required
Database answers build standard, answer as required
2022-06-24 04:24:00 【CSDN Q & A】
The table structure in the deli fresh food supermarket system is as follows :
Commodity list ( Product id , Name of commodity , Category , quality guarantee period ( God ), supplier );
Sales list ( Product id , Time , Customer number , The unit price , Number );
1. establish “ goods ” and “ sales ” These two basic tables , According to the actual situation , Design the data type of each field , The underscore in the structure identifies the primary key , Wavy lines identify foreign keys , And it is required that the product list “ Name of commodity ” The value is unique ,“ supplier ” Can't be empty ,“ quality guarantee period ” The default value is “30”; In the sales table “ The unit price ” stay 0 To 50000 Between .
2. Number the item as “056B5” The shelf life of the product is increased 10
God ;
3. Query the number of different items in the sales table ;
4. The query product name contains “ Crunchy Wafer ” Or the penultimate word is “ shark ” The commodity number of the word 、 Trade name and supplier .
5. Query category is “ Stationery ” And the unit price is 16 Commodity no. of more than RMB 、 Commodity name and unit price , It is required to arrange in descending order of unit price .
6. Create view view_sale, It is required to display the item number of each item sold 、 Average unit price and total quantity .
边栏推荐
- Easygbs video playback protocol only webrtc can play. Troubleshooting
- 3. go deep into tidb: perform optimization explanation
- [2021 "shadow seeking" medical artificial intelligence algorithm competition] frequently asked questions related to Ti-One products
- 多任务视频推荐方案,百度工程师实战经验分享
- web渗透测试----5、暴力破解漏洞--(6)VNC密码破解
- The official overclocking tool of Intel XTU supports win11 22h2 and 13th generation core Raptor Lake processors
- The first 2021 Western cloud security summit is coming! See you in Xi'an on September 26!
- Garbage collection mechanism
- [Mid Autumn Festival greeting new year with good gifts] Tengyun pioneer feedback exchange group received new benefits!
- Web penetration test - 5. Brute force cracking vulnerability - (6) VNC password cracking
猜你喜欢

博士申请 | 香港科技大学(广州)刘浩老师招收数据挖掘方向全奖博士/硕士

抢先报名丨新一代 HTAP 数据库如何在云上重塑?TiDB V6 线上发布会即将揭晓!

15+ urban road element segmentation application, this segmentation model is enough

Openeuler kernel technology sharing issue 20 - execution entity creation and switching

开源之夏2022中选结果公示,449名高校生将投入开源项目贡献

Clang代码覆盖率检测(插桩技术)

ServiceStack. Source code analysis of redis (connection and connection pool)

多任务视频推荐方案,百度工程师实战经验分享

Abnova荧光原位杂交(FISH)探针解决方案

15+城市道路要素分割应用,用这一个分割模型就够了
随机推荐
共建欧拉社区 共享欧拉生态|携手麒麟软件 共创数智未来
IDC, Youshang cloud data on cloud (COS) best practices
[2021 "shadow seeking" medical artificial intelligence algorithm competition] frequently asked questions related to Ti-One products
C string input considerations
Making a Chatbot based on gpt2
Web technology sharing | [map] to realize customized track playback
Wide & deep model and optimizer understand code practice
华为云GaussDB(for Redis)揭秘第19期:GaussDB(for Redis)全面对比Codis
How to adjust the incompleteness before and after TS slicing of easydss video recording?
一款支持内网脱机分享文档的接口测试软件
Abnova多肽设计和合成解决方案
Advanced authentication of uni app [Day12]
How to modify the channel name registered by the camera in the easygbs national standard platform?
How to do the right thing in digital marketing of consumer goods enterprises?
Web penetration test - 5. Brute force cracking vulnerability - (9) MS-SQL password cracking
What is FTP? What is the FTP address of the ECS?
Leetcode refers to offer II 089 House theft
Multi task video recommendation scheme, baidu engineers' actual combat experience sharing
web渗透测试----5、暴力破解漏洞--(9)MS-SQL密码破解
Openeuler kernel technology sharing issue 20 - execution entity creation and switching