程序模拟某公司的商品管理,商品信息包括:商品id,商品名称,价格,生产日期,产地,上架日期,库存;请新建数据库表进行商品信息管理,并使用控制台完成以下操作:
a)添加商品信息;
b)查询商品信息【商品名称全模糊匹配】;
c)修改商品信息-要求打印出修改前的商品信息和修改后的商品信息;
d)删除商品信息;
e)按上架日期降序显示所有商品
部分未完成`
pojo层
package com.iflytek.pojo;
public class Shop {
private int id;
private String name;
private double price;
private String createTime;
private String address;
private String saleTime;
private int store;
public Shop() {
// TODO Auto-generated constructor stub
}
public Shop(int id, String name, double price, String createTime, String address, String saleTime, int store) {
super();
this.id = id;
this.name = name;
this.price = price;
this.createTime = createTime;
this.address = address;
this.saleTime = saleTime;
this.store = store;
}
public int getId() {
return id;
}
public void setId(int id) {
this.id = id;
}
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public double getPrice() {
return price;
}
public void setPrice(double price) {
this.price = price;
}
public String getCreateTime() {
return createTime;
}
public void setCreateTime(String createTime) {
this.createTime = createTime;
}
public String getAddress() {
return address;
}
public void setAddress(String address) {
this.address = address;
}
public String getSaleTime() {
return saleTime;
}
public void setSaleTime(String saleTime) {
this.saleTime = saleTime;
}
public int getStore(