sqlite

SQLLite strftime not reading column value

烈酒焚心 提交于 2021-02-15 07:42:14
问题 i have this in my Sqllite Database query, i want ... select BoardingDate, strftime('%Y', date(BoardingDate)) from Hostels; but in the output it renders BoardingDate correctly and the output BoardingDate Month ------------------------- 8/1/2007 0:00:00 null 3/1/2008 0:00:00 null 8/1/2008 0:00:00 null 3/1/2009 0:00:00 null These is the current behaviour of the queries 1. strftime('%Y', date('now')) - outputs correctly 2. strftime('%Y', date('2020-03-06')) - it works also 3. strftime('%Y', date

multiple sql statements in QSqlQuery using the sqlite3 driver

陌路散爱 提交于 2021-02-15 04:05:37
问题 I have a file containing several SQL statements that I'd like to use to initialize a new sqlite3 database file. Apparently, sqlite3 only handles multiple statements in one query via the sqlite3_exec() function, and not through the prepare/step/finalize functions. That's all fine, but I'd like to use the QtSQL api rather than the c api directly. Loading in the same initializer file via QSqlQuery only executes the first statement, just like directly using the prepare/step/finalize functions

[开源] .Net ORM FreeSql 1.10.0 稳步向前

泄露秘密 提交于 2021-02-15 03:54:30
写在 开头 FreeSql 是 .NET 开源生态下的 ORM 轮子,转眼快两年了,说真的开源不容易(只有经历过才明白)。今天带点干货和湿货给大家,先说下湿货。 认识我的人,知道 CSRedisCore 是我写的另外一个开源组件,这个项目是 2016 年从 ctstone/csredis 项目 clone 到自己工作的项目中,修改源码经过一年多生产考验,于 2017 年发布开源 https://github.com/2881099/csredis ctstone/csredis 项目于 2014 年停止了更新,到我手里完善的功能如下: 连接池 哨兵高可用 集群 redis 2.8 以上的版本命令补充,包括 Geo、Stream 通讯协议 bug 修复 暂时想到的只有这些,之后可能再补充。FreeSql 文章标题为什么要来说 csredis? 这两年的时间里 95% 精力都用在了 FreeSql 上面, 5400+ 单元测试、支持十几种数据库适配,渣男辜负了 csredis 这个项目。最近一个多月开源圈子的奇葩事接二连三,居然有人跑去 ctstone/csredis 原作者的 issues 告我的状,这个告状的人还是 NOPI 原作者,因为当初他自己不维护 NPOI .NET Core 版本了,社区有好人把 .NET Core 版本测试做好了开源(dotnetcore/NPOI)

[开源] .Net ORM FreeSql 1.10.0 稳步向前

爷,独闯天下 提交于 2021-02-14 18:59:35
写在 开头 FreeSql 是 .NET 开源生态下的 ORM 轮子,转眼快两年了,说真的开源不容易(只有经历过才明白)。今天带点干货和湿货给大家,先说下湿货。 认识我的人,知道 CSRedisCore 是我写的另外一个开源组件,这个项目是 2016 年从 ctstone/csredis 项目 clone 到自己工作的项目中,修改源码经过一年多生产考验,于 2017 年发布开源 https://github.com/2881099/csredis ctstone/csredis 项目于 2014 年停止了更新,到我手里完善的功能如下: 连接池 哨兵高可用 集群 redis 2.8 以上的版本命令补充,包括 Geo、Stream 通讯协议 bug 修复 暂时想到的只有这些,之后可能再补充。FreeSql 文章标题为什么要来说 csredis? 这两年的时间里 95% 精力都用在了 FreeSql 上面, 5400+ 单元测试、支持十几种数据库适配,渣男辜负了 csredis 这个项目。最近一个多月开源圈子的奇葩事接二连三,居然有人跑去 ctstone/csredis 原作者的 issues 告我的状,这个告状的人还是 NOPI 原作者,因为当初他自己不维护 NPOI .NET Core 版本了,社区有好人把 .NET Core 版本测试做好了开源(dotnetcore/NPOI)

博客园app for xamarin android一款简洁阅读的博客园android客户端

荒凉一梦 提交于 2021-02-14 07:42:00
碎碎念回顾2017 一款简洁阅读的博客园android客户端,采用xamarin android框架 c#语言、原生的android应用。 到了年底,坐在转椅上,望着窗外的雾霾......从16年6月走出校门,已经做了1年半的码农,成长不少,但总觉得进步得不够明显,虽然工资比刚来的时候涨了不少,但是还是觉得自己不够努力。也不知道是老板给的压力太少,还是自己给自己的目标定的太短。 打开qq企业邮箱,找到去年给老大发的年度总结和计划,十分惭愧,去年的计划几乎只完成了50%。 1.多线程编程理解和运用不够熟练; 2.javascript还是停留在万金油jquery上; 3.signalr的聊天室也没搞完成; 4.计划了很久用xamarin android写个博客园也是拖了好久才完工。 5.前端自适应还是停留在bootstrap上的基础,拿着标签就干。 6.设计模式也还没有深入学习 7.android进阶的东西也还没有看 8.收藏夹的文章快大半年了,都没仔细学习,可能这就是“松鼠症”吧 9.说要学习英语,学习英语的app倒是下载4个,每天最多也就打开一次,没办法英语基础还是很差! 2018年的计划 前端自适应的学习 javascript面向对象编程 每天学习英语30分钟(可能感觉要黄) 完善自己的个人项目 c#设计模式的深入学习 webpack的掌握 维护个人博客(网站未做,服务器先行

centos7中安装python3.7.3

北慕城南 提交于 2021-02-12 09:18:22
环境: CentOS_7 (root用户) 软件版本: python_3.7.3 安装依赖包 yum -y groupinstall "Development tools" yum -y install zlib-devel bzip2-devel openssl-devel ncurses-devel sqlite-devel readline-devel tk-devel gdbm-devel db4-devel libpcap-devel xz-devel libffi-devel 下载软件源码 Python-3.7.3 wget https://www.python.org/ftp/python/3.7.3/Python-3.7.3.tgz 解压并编译源码 tar zxvf Python-3.7.3.tgz cd Python-3.7.3/ ./configure --prefix=/usr/local/python-3.7.3 make && make install 配置软链接 ln -s /usr/local/python-3.7.3/bin/python3.7 /usr/bin/python3 ln -s /usr/local/python-3.7.3/bin/pip3.7 /usr/bin/pip3 验证 python3 -V Python 3.7.3 -----

How to encrypt sqlite texts without 3rd party libraries (Android)

混江龙づ霸主 提交于 2021-02-11 18:11:35
问题 I'm using an external database inside my android application and it directly embeds inside the apk package after compiling. As I want to implement in app purchase in order to access some of its data I don't want to leave it without any encryption. I used Sqlcipher library but it makes the app too big and slow. Isn't there any other way to do this? For example an algorithm to encrypt the strings so I put the encrypted text in database and decrypt it inside application code? 回答1: The following

How to encrypt sqlite texts without 3rd party libraries (Android)

谁说我不能喝 提交于 2021-02-11 18:09:49
问题 I'm using an external database inside my android application and it directly embeds inside the apk package after compiling. As I want to implement in app purchase in order to access some of its data I don't want to leave it without any encryption. I used Sqlcipher library but it makes the app too big and slow. Isn't there any other way to do this? For example an algorithm to encrypt the strings so I put the encrypted text in database and decrypt it inside application code? 回答1: The following

Why am I getting an sqlite3 error 14 (unable to open database) when calling step on an sqlite3_stmt?

别说谁变了你拦得住时间么 提交于 2021-02-11 18:01:49
问题 I am experiencing an SQLite error when attempting to step on an sqlite3_stmt . Surprisingly, I got the error 14: unable to open database file . This is confusing as I opened the database earlier, and successfully submitted an insert into one of the tables. At no point did I close the database. BEGIN TRANSACTION INSERT to table A INSERT to table B END TRANSACTION When I attempt to run the second insert command, I get the failure. Does anyone have any idea of what might cause this issue? 回答1:

Room exception on table: Pre-packaged database has an invalid schema

99封情书 提交于 2021-02-11 17:25:28
问题 my task is to migrate the current architecture of our app (using Cupboard) to Room and I am encountering some issues on the very first piece of work, which is migrating the database objects, written in Java for now (Cupboard only supports Java), to make them work with Room. This is an example: public class ItemDb { public Long _id; public String type; public String subtype; public long scheduledTime; public int iteration; public String data1; public String data2; public String data3; and this