from peewee import * db = MySQLDatabase("91jiafan", host="127.0.0.1", port=3306, user="root", password="123456") class BaseModel(Model): class Meta: d ...
分类:
数据库 时间:
2020-07-03 19:16:22
阅读次数:
79
csv 中 某一列对应数据库表 timestamp 类型 该列为空时 '',插入会报错 Incorrect datetime value: '' for column 解决方案: mysql> set session sql_mode=''; Query OK, 0 rows affected, 1 ...
分类:
数据库 时间:
2020-07-03 17:05:37
阅读次数:
108
定义事件: -- 定义事件,删除10天前数据,并指定每5秒执行一次;Event_syslog为事件名称 CREATE EVENT IF NOT EXISTS Event_syslog ON SCHEDULE EVERY 5 SECOND STARTS curdate() ON COMPLETION ...
分类:
数据库 时间:
2020-07-03 01:02:21
阅读次数:
148
多Sheet导入教程 说明 本教程主要说明如何使用Magicodes.IE.Excel完成多个Sheet数据的Excel导入。 要点 多个相同格式的Sheet数据导入 多个不同格式的Sheet数据导入 主要步骤 1. 多个相同格式的Sheet数据导入 1.1 创建导入Sheet的Dto 主要代码如下 ...
分类:
Web程序 时间:
2020-07-02 13:19:26
阅读次数:
60
设计表如下 --收入表 CREATE TABLE income ( inid INT PRIMARY KEY IDENTITY(1, 1), indate DATETIME, --时间 intype VARCHAR(10), -- 收入类型 amount DECIMAL(18, 2) --金额 ) ...
分类:
数据库 时间:
2020-07-02 10:45:44
阅读次数:
58
一、time模块 1.time.strptime :将时间字符串转化为时间类型 格式:time.strptime(string[string[, format]) 结果可以利用利用time.tm_year 返回年份,其余雷同。 #例子 >>> t = time.strptime("2018-2-2" ...
分类:
编程语言 时间:
2020-07-02 10:40:32
阅读次数:
75
用于监控程序在那个阶段的运行时间较长 for(int i=0;i<=XList.Count -1;i++) { //获取开始时间 DateTime d1 = DateTime.Now; //进行修改操作 idata += _bllGongZiList.SetUptmdGongZiList(XList ...
string datecompare = Convert.ToDateTime(swipeCardRecord.OnStationTime).ToLongDateString(); string datenow = DateTime.Now.ToLongDateString(); ...
分类:
其他好文 时间:
2020-07-01 09:59:01
阅读次数:
128
using System;using System.Collections.Generic;using System.Linq;using System.Text;using System.Threading.Tasks; using ServiceStack.Redis; namespace te ...
分类:
其他好文 时间:
2020-07-01 09:36:28
阅读次数:
65
public static void TextWriter(string Msg) { string path = @"D: " + "log.txt"; //文件流 FileStream file = new FileStream(path, FileMode.Append); StreamWri ...
分类:
其他好文 时间:
2020-06-30 20:23:32
阅读次数:
41