——————————————————————————————————
mysqluse you_database; load data infile 'F:/MySqlData/test1.csv' --CSV文件存放路径 into table student--要将数据导入的表名 fields terminated by ',' optionally enclosed by '"' escaped by '"' lines terminated by '\r\n';
mysqlload data local infile 'file_path' # 文件路径 into table daily_price # 表名 character set utf8 # 编码 fields terminated by ',' # 分隔符 lines terminated by '\r\n' # 换行符,windows下是\r\n ignore 1 lines; # 忽略第一行,因为表头已建好
js//在mounted里写(这是示例)
var myChart = echarts.init(document.getElementById('echartContainer'));
myChart.setOption({
title: { text: '示例' },
tooltip: {},
xAxis: {
data: ["衬衫","羊毛衫","雪纺衫","裤子","高跟鞋","袜子"]
},
yAxis: {},
series: [{
realtimeSort: true,
barWidth: 14,
barGap: 10,
smooth: true,
valueAnimation: true,
name: '销量',
type: 'bar',
data: [5, 20, 36, 10, 10, 20]
}]
});
html<!--在html里写(这是示例)-->
<div id="app">
<div id="echartContainer" style="width:400px; height:400px"></div>
</div>
jslet echarts = require('echarts/lib/echarts');
require('echarts/lib/chart/line')
require('echarts/lib/chart/bar')
require('echarts/lib/chart/radar')
require('echarts/lib/component/tooltip')
require('echarts/lib/component/title')
require('echarts/lib/component/legend')
require('echarts/lib/component/legendScroll')
Vue.prototype.$echarts = echarts
本文作者:Байт
本文链接:
版权声明:本博客所有文章除特别声明外,均采用 BY-NC-SA 许可协议。转载请注明出处!