- 关于提高复杂业务逻辑代码可读性的思考
编程经验分享
开发经验java数据库开发语言
目录前言需求场景常规写法拆分方法领域对象总结前言实际工作中大部分时间都是在写业务逻辑,一般都是三层架构,表示层(Controller)接收客户端请求,并对入参做检验,业务逻辑层(Service)负责处理业务逻辑,一般开发都是在这一层中写具体的业务逻辑。数据访问层(Dao)是直接和数据库交互的,用于查数据给业务逻辑层,或者是将业务逻辑层处理后的数据写入数据库。简单的增删改查接口不用多说,基本上写好一
- 为了那一个约定
王书朋
我和我的学生说好了,不管遇到什么,都要一起努力,这是我们刚遇见时留下的记忆,到现在刚好一年过去。在本周一,我做了一个简单的询问,想看一看经过一个漫长的假期,还有几个人记得努力,所以我一个人一个人的问下去。我所问的内容,就是你有没有记日记和进行课外阅读,两个班将近一百名学生,在我没有要求的情况下。主要是上个学期我们遇到了特殊情况,还没来得及做出要求,就已经进入了假期,因此阴差阳错,为我制造了检验学生
- 练就理论联系实际的真功夫
TBC
理论联系实际是中国共产党的三大作风之一,理论从实际中来,要到实际中去。理论不是唯一的真理,理论要在现实中接受实践的检验,才能更好地指导实践,理论脱离实际就会变成一种僵硬的教条,茶杯硬套锅盖,风马牛不相及。理论从实际中来,并接受实践的检验。理论是一种经验总结,是我们的指导手册,引导我们的方向盘,它能指引我们在贯彻落实工作中少走弯路。理论是前人阶段性工作的经验总结,它使得我们能站在“巨人的肩膀”上更为
- 晨语问安2022年1月3日
求索大伟
『晨语问安1.3』实践出真知,实践是检验真理的。实践,毋庸置疑是检验能力、验证自我最有力的工具,而恰恰实践或称为行动,却是自身前行的最大的弱项,借用最亲近的人说我的一句话“不会用剩余生命陪我慢慢变好”,由此可见,执行力在我身上是何其弱小。同时,这与自己一直标榜积极向上的精神状态南辕北辙,越走越远。问题清楚呈现,改变刻不容缓,重点在于执行,绝非和风细雨,而应立竿见影,更要坚持不懈。早安,开心一天。[
- 制衣厂的故事13
记忆里的角落
我们的主任是一位胖美人,她别的本事没有,就会在我们面前摆官腔架子。“L码的衣服是谁验的,这么一大块脏污都没看加啊?你们验货闭着眼吗?”没说我们眼瞎不是她厚道,而是我们跟她斗争得来的结果,嗯,还算满意。她拿着一件衣服,站在包装车间跟我们车间相连的门边上对着我们高声喊,板娘就在她身后的包装车间陪着客户检验货。我们心里别提有多反感这种拿腔捏调,还没等有人回答,啪唧,衣服老远扔过来落在小刘前面。我使了个眼
- 2022-03-28打开格局,勇敢背黑锅
心源之园
在例会上,老板批评了我和另外一个部门的负责人,原因是我们给客户的报价是在询价的一周后才给出。老板希望是24小时内给出报价。让我们两个部门反思检讨。经过几天的内心挣扎和思想斗争,最终我还是给老板写了深刻检讨的邮件,承认主要责任,并提出了几项优化部门间合作流程的方案计划。美国作家菲茨杰拉德说:检验一流智力的标准,就是看你能不能在头脑中同时存在两种相反的想法,还维持正常行事的能力。我觉得这也可以用于评判
- 食品检验师职业资格试题附答案
安建资小栗子
其他
1、酸碱指示剂的变色原理是(C)。(A)随pH改变,指示剂离解常数改变,发生色变(B)随pH改变,指示剂结构发生改变,引起色变(C)随pH改变,指示剂起化学反应,引起色变:(D)随pH改变,指示剂发生物理化学反应,引起色变2、下列哪种微生物具有典型细胞核结构(C)。(A)沙门氏菌(B)桔青霉菌(C)葡萄球菌(D)大肠杆菌3、两种生物生活在一起,互相依赖,互相利用的这种关系称为(A)。(A)共生(B
- python卡方检验计算pvalue值_Python数据科学:卡方检验
CodeWhiz
之前已经介绍的变量分析:①相关分析:一个连续变量与一个连续变量间的关系。②双样本t检验:一个二分分类变量与一个连续变量间的关系。③方差分析:一个多分类分类变量与一个连续变量间的关系。本次介绍:卡方检验:一个二分分类变量或多分类分类变量与一个二分分类变量间的关系。如果其中一个变量的分布随着另一个变量的水平不同而发生变化时,那么两个分类变量就有关系。卡方检验并不能展现出两个分类变量相关性的强弱,只能展
- python 卡方检验_Python-卡方检验
cunzai1985
pythonnumpy数据分析机器学习数据挖掘
python卡方检验Python-卡方检验(Python-Chi-SquareTest)Chi-Squaretestisastatisticalmethodtodetermineiftwocategoricalvariableshaveasignificantcorrelationbetweenthem.Boththosevariablesshouldbefromsamepopulationand
- 【Python・统计学】威尔科克森符号秩检验/Wilcoxon signed-rank test(原理及代码)
TUTO_TUTO
统计学pythonpython学习笔记
前言自学笔记,分享给对统计学原理不太清楚但需要在论文中用到的小伙伴,欢迎大佬们补充或绕道。ps:本文不涉及公式讲解(文科生小白友好体质)~(部分定义等来源于知乎百度等)本文重点:威尔科克森符号秩检验(英文名:Wilcoxonsigned-ranktest)【1.简单原理和步骤】【2.应用条件】【3.数据实例以及Python代码】1.简单原理和步骤威尔科克森符号秩检验是一种非参数检验的方法,需要数据
- 【Python・统计学】Kruskal-Wallis检验/H检验(原理及代码)
TUTO_TUTO
python统计学python学习笔记
前言自学笔记,分享给对统计学原理不太清楚但需要在论文中用到的小伙伴,欢迎大佬们补充或绕道。ps:本文不涉及公式讲解(文科生小白友好体质)~(部分定义等来源于知乎百度等)本文重点:Kruskal-Wallis检验(Kruskal-Wallistest),也称H检验【1.定义和简单原理】【2.应用条件】【3.数据实例以及Python代码】【4.多重比较(例:Dunn检验)】1.定义和简单原理Krusk
- 【Python・统计学】单因素方差分析(简单原理及代码)
TUTO_TUTO
统计学pythonpython学习笔记
前言自学笔记,分享给对统计学原理不太清楚但需要在论文中用到的小伙伴,欢迎大佬们补充或绕道。ps:本文不涉及公式讲解(文科生小白友好体质)~本文重点:单因素方差分析(以下:方差分析)【1.方差分析简单原理和前提条件】【2.方差分析和t检验的区别】【3.方差分析代码(配对/独立+事后检验+效应量)】1.方差分析简单原理方差分析(ANOVA)又称“变异数分析”或“F检验”,是由罗纳德·费雪爵士发明的,用
- 【统计学】参数检验和非参数检验的区别和基本统计学
TUTO_TUTO
统计学pythonpython
前言自学笔记,分享给对统计学原理不太清楚但需要在论文中用到的小伙伴,欢迎大佬们补充或绕道。ps:本文不涉及公式讲解(文科生小白友好体质)~本文重点:参数检验和非参数检验的区别以及对应的常用统计学方法(这是需要根据自己的数据类型搞清楚用哪种统计学方法的关键)【1.参数检验】【2.非参数检验】【3.参数检验和非参数检验的区别】【4.常用统计学方法】1.什么是参数和参数检验参数(parameter)的概
- TCP和UDP的区别
life_binary
Linux网络编程
TCP和UDP都是传输层的协议TCP面向连接的、可靠地、数据流服务UDP无连接的、不可靠的、数据报服务那么为什么TCP可靠,为什么UDP不可靠呢?也就是是什么保证了TCP是可靠的呢?共有四点原因:1、TCP保证数据都能到达对端。是通过应答确认机制和超时重传机制来保证的。2、TCP保证数据有序。TCP的每一个报文段都有序号3、TCP保证数据不失真。TCP报头有16位的冗余检验码4、滑动窗口和拥塞控制
- 《华为人力资源理论》读书笔记
龚_温暖的弦
整理一下目录主要选看了全员赋能,市场实践和检验,权益分配三部分全员赋能市场实践和检验权益分配
- 检验爱情其实不用去旅游,一起煮顿饭吃就知道了
书生的英雄联萌
大家好,又是我,我是书生。一个勤奋更新的书生~~~最近有2天没有更新了,前天是身体不舒服,躺了好久,连面试都没有去,可怜的我;然后昨天好了点,就跑去浪,浪完以后又跑回家,这回家的人群,真的可怕。搞到我还以为今天是中秋呢??然后退了晚点了两个小时的车票,晚上8点搭地铁+滴滴,终于回到我大南海,然后告诉我24才是中秋,那高速提前2天塞了?有人说,检验爱情吧,一起去趟旅游吧。不用看,肯定是某些旅游营销号
- 成为我自己—41生病的获益
心喜欢生0003
昨天晚上观摩精分咨询,我感受到了来访生病的获益。但我也感受到了咨询师的愤怒,我感觉咨询师有一点对这个公益咨询的愤怒,不知道是不是我的投射?但我又觉得这个愤怒是社会化的一部分,咨询最终是需要成长的,需要放进社会的大熔炉里检验。我觉察了一下自己的愤怒:这是我对父母的恨意。一直以来我都有勇气恨我的父亲,却一直没有勇气恨我的母亲,因为她为这个家庭付出了太多;可是这付出,也是命运的一部分啊。我一直记得八岁那
- 03月26日长光培训嵌入式学习第四十七天课设第一天
长光培训_王任
早上接到钟老师的通知周日答辩!!这意味着终于到了对这几个月来学习成果的检验时刻。一周的时间完成智能家居嵌入式系统的开发,将课程所学内容进行融合和综合应用,也是对从理论到实践的一次能力提升之旅。今天主要的任务是明确自身要完成的功能,进行管脚及各种通信协议的统筹分配与全局规划,为后几天的编译做好准备工作。好的开头是成功的一半,对于准备工作一定要做到认真细致,只有这样才会让自己在后面几天中能够按照计划有
- 光明的前奏
坤哥1022
图片发自App早上十点来钟,应是大白天,没想到突然天气急转直下,乌云密布,大风吹得路旁的花花和树叶沙沙响,接着雨噼噼啪啪地下起来,犹如“世界末日”。路上行人匆匆赶路,狼狈而慌乱。怎么啦?是上天动怒了?谁做了坏事?该是上天的脾气来了,再不收手,将是更大的惩罚。大风劲吹,考验着花花的根基,清理着树上的枯枝和黄叶;检验着树枝的团结与坚强;锻炼着鸟儿的起飞反应。大雨鞭打着窗户,是给违法犯科者的警告,还是对
- 助梦语录句句入魂020
助梦飞飞
1.有些路,不走,不甘心,走了,满身伤痕,人生或许就这样吧,无论怎么选择都有遗憾,无论怎么精心策划,都抵不过命运的安排。2.人生本就是一场孤独的成长,没有多少人会陪你一直走到散场。时间检验了人性,验证了人心。它能告诉你什么样的东西是经久耐用的,什么样的人是可以历久弥新的。3.心不死,则道不生,心有一切有,心空一切空,心迷一切迷,心悟一切悟,心邪一切邪,心正一切正,心乱一切乱!一切为心造,无心自解脱
- 2022-11-03
平白书
一、每日感谢1、今天去体检,排队进医院的时候,结识了一位排在我后面的阿姨。阿姨68岁了,来做65岁以上福利体检。原本以为和不相熟的人没什么好说的,但不然,要看碰到的是谁。我和阿姨聊了二十分钟,许多观点不谋而合。像对检验数据的看法。我们提到是不是应该每年一次深度体检。阿姨说不用太看重检验数据的正常区间,其实每个人的情况都不一样,最重要是自己要感觉舒服。“参考数据范畴”仅仅是参考。再就是对死亡的看法。
- 再出发
稣趣
6月13日,我失业了。没有一点预兆,领导说,马上旺季了,怕我应付不了。6月14日,只做了一件事,无偿献血,刚刚收到短信,血液检验合格。6月15日,参加了孩子幼儿园的家长学堂,学习一些教育孩子过程中非常好的方法,孩子一天天成长,经常无意识地错过了许多让他变得更好的时候。6月16日,搬家,从住了一年的地方搬出去,拉了四车才搬完东西,已经忘记当初搬进来的场景,一晃一年过去了,一切似乎回到了原点,重新开始
- Python 数学建模——方差分析
Desire.984
Python数学建模数学建模python概率论
文章目录前言单因素方差分析原理核心代码双因素方差分析数学模型分析依据典型代码前言 方差分析也是概率论中非常重要的内容,有时数学建模需要用到。方差分析是干什么的?如果说假设检验用于分析两个总体之间的均值μ1,μ2\mu_1,\mu_2μ1,μ2是否存在显著的差别,那么方差分析就是分析两个以上总体之间的均值是否存在显著的差别。单因素方差分析用途:已知一个量AAA可能会影响XXX,AAA的不同取值可能
- 2023-07-18
HS2011
采血注意事项——如何保证采血标本质量?在采血前由于病人受到各种内在和外界的影响,会使得检验结果产生或大或小的误差,为了减少随机分析误差,采血前病人需要注意以下几点:1、基本要求患者在采血前24小时内应避免运动和饮酒,不宜改变饮食习惯和睡眠习惯,采血最好在起床后1小时内进行,以上午7~9时为适宜,应避免使用任何药物:不少抗生素、镇痛消炎药、激素类药甚至维生素等都可影响检验结果。比如维生素C就会明显干
- 阅读《认知天性:让学习轻而易举的心理学规律》的第十一天
富宁083范琳琳
阅读内容:第二章《学习的本质知识链和记忆结》-为何学习越轻松,效果越不好?阅读分享:当我看到这张标题的时候想到了《学习的逻辑》里面提到的,要想提高我们的学习效率和记忆力,就得提高大脑的活跃度。提高大脑的活跃度就意味着大脑会消耗身体大量的能量,而此时的人就容易出现疲劳和饥饿的状态。所以学习并不是一件轻松的事情,要想学习效果好,更是要花大量的精力。这一章作者一直都坚定的在讨论检验和检索练习,在学习中的
- 计算机类毕业设计怎么做
李哥讲程序开发
课程设计毕设毕业设计
计算机类的毕业设计通常是学生在大学学习期间的一个综合实践项目,旨在检验学生对所学知识的掌握程度以及解决实际问题的能力。以下是一些步骤和建议,可以帮助你完成计算机类的毕业设计:1.**选题与定位**:-选择一个你感兴趣的主题,这有助于保持动力并完成项目。-确保题目具有实际应用价值或理论研究意义。-考虑你的技能和知识水平,确保选择的题目既有挑战性又能够实现。2.**文献调研**:-阅读相关的书籍、学术
- 【免费培训 · 时间调整】脑电统计分析专题班(直播:2023.7.12)
茗创科技
课程背景统计分析通过对数据进行定量和定性分析,使繁杂的数据变得直观且形象。它作为一门实践性很强的课程,对各学科领域的发展起着非常重要的作用,特别是作为一种认识心理现象数量特征的重要工具受到了广大心理学工作者的重视。统计分析有助于建立问题和数据之间的关系,从而更好地了解和发现事物的内在规律。但如果大家在科研数据分析过程中只是记住操作步骤,缺乏对各种统计分析方法的原理、应用条件和检验结果的理解,不能很
- 数据分析-18-时间序列分析的季节性检验
皮皮冰燃
数据分析数据分析
1什么是时间序列时间序列是一组按时间顺序排列的数据点的集合,通常以固定的时间间隔进行观测。这些数据点可以是按小时、天、月甚至年进行采样的。时间序列在许多领域中都有广泛应用,例如金融、经济学、气象学和工程等。时间序列的分析可以帮助我们理解和预测未来的趋势和模式,以及了解数据的周期性、趋势、季节性等特征。常用的时间序列分析方法包括平滑法、回归分析、ARIMA模型、指数平滑法和机器学习方法等。1.1时间
- 《巴比伦富翁的理财课》第十课 D13
坤道率然
幸运女神永远偏爱付诸行动的人《巴比伦富翁的理财课》即将结束,通过再次阅读,让自己重新温习理财的若干原理与法则,对近期的迷茫与懈怠起了很好的警示作用,也更好的反思自己,通过不断的自省与反思,拷问内心,更明白自己追求的到底是什么:自由——财务自由,身体自由,心灵自由。无论阅读多少书籍,要想幸运降临最重要的一点就是立即行动,从你阅读的那一刻起,按照你所理解的知识或认识去实践,在现实生活中检验和加深对知识
- Python 数学建模——假设检验
Desire.984
Python数学建模python数学建模概率论
文章目录前言参数假设检验单个总体均值的假设检验σ\sigmaσ已知σ\sigmaσ未知两个总体均值的假设检验参考代码非参数假设检验分布拟合检验——卡方检验KS检验(Kolmogorov-Smirnov检验)Wilcoxon检验Wilcoxon符号秩检验Wilcoxon秩和检验前言 假设检验是概率论中相当重要的内容。一般是先提出一个原假设H0H_0H0和一个对立的备择假设H1H_1H1,通过数学方
- springmvc 下 freemarker页面枚举的遍历输出
杨白白
enumfreemarker
spring mvc freemarker 中遍历枚举
1枚举类型有一个本地方法叫values(),这个方法可以直接返回枚举数组。所以可以利用这个遍历。
enum
public enum BooleanEnum {
TRUE(Boolean.TRUE, "是"), FALSE(Boolean.FALSE, "否");
- 实习简要总结
byalias
工作
来白虹不知不觉中已经一个多月了,因为项目还在需求分析及项目架构阶段,自己在这段
时间都是在学习相关技术知识,现在对这段时间的工作及学习情况做一个总结:
(1)工作技能方面
大体分为两个阶段,Java Web 基础阶段和Java EE阶段
1)Java Web阶段
在这个阶段,自己主要着重学习了 JSP, Servlet, JDBC, MySQL,这些知识的核心点都过
了一遍,也
- Quartz——DateIntervalTrigger触发器
eksliang
quartz
转载请出自出处:http://eksliang.iteye.com/blog/2208559 一.概述
simpleTrigger 内部实现机制是通过计算间隔时间来计算下次的执行时间,这就导致他有不适合调度的定时任务。例如我们想每天的 1:00AM 执行任务,如果使用 SimpleTrigger,间隔时间就是一天。注意这里就会有一个问题,即当有 misfired 的任务并且恢复执行时,该执行时间
- Unix快捷键
18289753290
unixUnix;快捷键;
复制,删除,粘贴:
dd:删除光标所在的行 &nbs
- 获取Android设备屏幕的相关参数
酷的飞上天空
android
包含屏幕的分辨率 以及 屏幕宽度的最大dp 高度最大dp
TextView text = (TextView)findViewById(R.id.text);
DisplayMetrics dm = new DisplayMetrics();
text.append("getResources().ge
- 要做物联网?先保护好你的数据
蓝儿唯美
数据
根据Beecham Research的说法,那些在行业中希望利用物联网的关键领域需要提供更好的安全性。
在Beecham的物联网安全威胁图谱上,展示了那些可能产生内外部攻击并且需要通过快速发展的物联网行业加以解决的关键领域。
Beecham Research的技术主管Jon Howes说:“之所以我们目前还没有看到与物联网相关的严重安全事件,是因为目前还没有在大型客户和企业应用中进行部署,也就
- Java取模(求余)运算
随便小屋
java
整数之间的取模求余运算很好求,但几乎没有遇到过对负数进行取模求余,直接看下面代码:
/**
*
* @author Logic
*
*/
public class Test {
public static void main(String[] args) {
// TODO A
- SQL注入介绍
aijuans
sql注入
二、SQL注入范例
这里我们根据用户登录页面
<form action="" > 用户名:<input type="text" name="username"><br/> 密 码:<input type="password" name="passwor
- 优雅代码风格
aoyouzi
代码
总结了几点关于优雅代码风格的描述:
代码简单:不隐藏设计者的意图,抽象干净利落,控制语句直截了当。
接口清晰:类型接口表现力直白,字面表达含义,API 相互呼应以增强可测试性。
依赖项少:依赖关系越少越好,依赖少证明内聚程度高,低耦合利于自动测试,便于重构。
没有重复:重复代码意味着某些概念或想法没有在代码中良好的体现,及时重构消除重复。
战术分层:代码分层清晰,隔离明确,
- 布尔数组
百合不是茶
java布尔数组
androi中提到了布尔数组;
布尔数组默认的是false, 并且只会打印false或者是true
布尔数组的例子; 根据字符数组创建布尔数组
char[] c = {'p','u','b','l','i','c'};
//根据字符数组的长度创建布尔数组的个数
boolean[] b = new bool
- web.xml之welcome-file-list、error-page
bijian1013
javaweb.xmlservleterror-page
welcome-file-list
1.定义:
<welcome-file-list>
<welcome-file>login.jsp</welcome>
</welcome-file-list>
2.作用:用来指定WEB应用首页名称。
error-page1.定义:
<error-page&g
- richfaces 4 fileUpload组件删除上传的文件
sunjing
clearRichfaces 4fileupload
页面代码
<h:form id="fileForm"> <rich:
- 技术文章备忘
bit1129
技术文章
Zookeeper
http://wenku.baidu.com/view/bab171ffaef8941ea76e05b8.html
http://wenku.baidu.com/link?url=8thAIwFTnPh2KL2b0p1V7XSgmF9ZEFgw4V_MkIpA9j8BX2rDQMPgK5l3wcs9oBTxeekOnm5P3BK8c6K2DWynq9nfUCkRlTt9uV
- org.hibernate.hql.ast.QuerySyntaxException: unexpected token: on near line 1解决方案
白糖_
Hibernate
文章摘自:http://blog.csdn.net/yangwawa19870921/article/details/7553181
在编写HQL时,可能会出现这种代码:
select a.name,b.age from TableA a left join TableB b on a.id=b.id
如果这是HQL,那么这段代码就是错误的,因为HQL不支持
- sqlserver按照字段内容进行排序
bozch
按照内容排序
在做项目的时候,遇到了这样的一个需求:
从数据库中取出的数据集,首先要将某个数据或者多个数据按照地段内容放到前面显示,例如:从学生表中取出姓李的放到数据集的前面;
select * fro
- 编程珠玑-第一章-位图排序
bylijinnan
java编程珠玑
import java.io.BufferedWriter;
import java.io.File;
import java.io.FileWriter;
import java.io.IOException;
import java.io.Writer;
import java.util.Random;
public class BitMapSearch {
- Java关于==和equals
chenbowen00
java
关于==和equals概念其实很简单,一个是比较内存地址是否相同,一个比较的是值内容是否相同。虽然理解上不难,但是有时存在一些理解误区,如下情况:
1、
String a = "aaa";
a=="aaa";
==> true
2、
new String("aaa")==new String("aaa
- [IT与资本]软件行业需对外界投资热情保持警惕
comsci
it
我还是那个看法,软件行业需要增强内生动力,尽量依靠自有资金和营业收入来进行经营,避免在资本市场上经受各种不同类型的风险,为企业自主研发核心技术和产品提供稳定,温和的外部环境...
如果我们在自己尚未掌握核心技术之前,企图依靠上市来筹集资金,然后使劲往某个领域砸钱,然
- oracle 数据块结构
daizj
oracle块数据块块结构行目录
oracle 数据块是数据库存储的最小单位,一般为操作系统块的N倍。其结构为:
块头--〉空行--〉数据,其实际为纵行结构。
块的标准大小由初始化参数DB_BLOCK_SIZE指定。具有标准大小的块称为标准块(Standard Block)。块的大小和标准块的大小不同的块叫非标准块(Nonstandard Block)。同一数据库中,Oracle9i及以上版本支持同一数据库中同时使用标
- github上一些觉得对自己工作有用的项目收集
dengkane
github
github上一些觉得对自己工作有用的项目收集
技能类
markdown语法中文说明
回到顶部
全文检索
elasticsearch
bigdesk elasticsearch管理插件
回到顶部
nosql
mapdb 支持亿级别map, list, 支持事务. 可考虑做为缓存使用
C
- 初二上学期难记单词二
dcj3sjt126com
englishword
dangerous 危险的
panda 熊猫
lion 狮子
elephant 象
monkey 猴子
tiger 老虎
deer 鹿
snake 蛇
rabbit 兔子
duck 鸭
horse 马
forest 森林
fall 跌倒;落下
climb 爬;攀登
finish 完成;结束
cinema 电影院;电影
seafood 海鲜;海产食品
bank 银行
- 8、mysql外键(FOREIGN KEY)的简单使用
dcj3sjt126com
mysql
一、基本概念
1、MySQL中“键”和“索引”的定义相同,所以外键和主键一样也是索引的一种。不同的是MySQL会自动为所有表的主键进行索引,但是外键字段必须由用户进行明确的索引。用于外键关系的字段必须在所有的参照表中进行明确地索引,InnoDB不能自动地创建索引。
2、外键可以是一对一的,一个表的记录只能与另一个表的一条记录连接,或者是一对多的,一个表的记录与另一个表的多条记录连接。
3、如
- java循环标签 Foreach
shuizhaosi888
标签java循环foreach
1. 简单的for循环
public static void main(String[] args) {
for (int i = 1, y = i + 10; i < 5 && y < 12; i++, y = i * 2) {
System.err.println("i=" + i + " y="
- Spring Security(05)——异常信息本地化
234390216
exceptionSpring Security异常信息本地化
异常信息本地化
Spring Security支持将展现给终端用户看的异常信息本地化,这些信息包括认证失败、访问被拒绝等。而对于展现给开发者看的异常信息和日志信息(如配置错误)则是不能够进行本地化的,它们是以英文硬编码在Spring Security的代码中的。在Spring-Security-core-x
- DUBBO架构服务端告警Failed to send message Response
javamingtingzhao
架构DUBBO
废话不多说,警告日志如下,不知道有哪位遇到过,此异常在服务端抛出(服务器启动第一次运行会有这个警告),后续运行没问题,找了好久真心不知道哪里错了。
WARN 2015-07-18 22:31:15,272 com.alibaba.dubbo.remoting.transport.dispatcher.ChannelEventRunnable.run(84)
- JS中Date对象中几个用法
leeqq
JavaScriptDate最后一天
近来工作中遇到这样的两个需求
1. 给个Date对象,找出该时间所在月的第一天和最后一天
2. 给个Date对象,找出该时间所在周的第一天和最后一天
需求1中的找月第一天很简单,我记得api中有setDate方法可以使用
使用setDate方法前,先看看getDate
var date = new Date();
console.log(date);
// Sat J
- MFC中使用ado技术操作数据库
你不认识的休道人
sqlmfc
1.在stdafx.h中导入ado动态链接库
#import"C:\Program Files\Common Files\System\ado\msado15.dll" no_namespace rename("EOF","end")2.在CTestApp文件的InitInstance()函数中domodal之前写::CoIniti
- Android Studio加速
rensanning
android studio
Android Studio慢、吃内存!启动时后会立即通过Gradle来sync & build工程。
(1)设置Android Studio
a) 禁用插件
File -> Settings... Plugins 去掉一些没有用的插件。
比如:Git Integration、GitHub、Google Cloud Testing、Google Cloud
- 各数据库的批量Update操作
tomcat_oracle
javaoraclesqlmysqlsqlite
MyBatis的update元素的用法与insert元素基本相同,因此本篇不打算重复了。本篇仅记录批量update操作的
sql语句,懂得SQL语句,那么MyBatis部分的操作就简单了。 注意:下列批量更新语句都是作为一个事务整体执行,要不全部成功,要不全部回滚。
MSSQL的SQL语句
WITH R AS(
SELECT 'John' as name, 18 as
- html禁止清除input文本输入缓存
xp9802
input
多数浏览器默认会缓存input的值,只有使用ctl+F5强制刷新的才可以清除缓存记录。如果不想让浏览器缓存input的值,有2种方法:
方法一: 在不想使用缓存的input中添加 autocomplete="off"; eg: <input type="text" autocomplete="off" name