- 浏览: 56216 次
文章分类
- 全部博客 (46)
- java邮件组件 (1)
- java excel上传 (3)
- java 导出excel (1)
- java文件上传 (1)
- java文件上传、下载 (1)
- mytatis插件 (1)
- jquery.validate.min.js 非空验证 (1)
- 常用js工具 (2)
- 编程规范 (1)
- art.dialog页面 (1)
- java常量配置 (1)
- 框架知识 (2)
- web页面前段技术 (3)
- Method方法反射机制 (1)
- 数据库 (5)
- java解析excel数据 (1)
- java 反射 (1)
- spring 注解 (2)
- mybatis (4)
- Eclipse 模板 (1)
- web页面前端技术 (3)
- java 1.8 (1)
- 111111 (0)
- EL (1)
- mysql 分页 (1)
- excel导出 (1)
- 页面通用查询保存方法 (1)
- 自动创建数据库脚本 (1)
- 重复提交后台校验 (1)
- maven (1)
最新评论
记事本
-------------------------------------------------------------------------------------
excel脚本:
="insert into plf_pur_warehouse_contact(id,factory_code,whouse_code,emp_no,emp_name,emp_tel,emp_email) values(REPLACE(UUID(),'-',''),'"&B2&"','"&D2&"','"&H2&"','"&I2&"','"&J2&"','"&K2&"');"
然后下拉。
-------------------------------------------------------------------------------------
sql:
SET @int = (SELECT MAX(id) FROM um_user)
SELECT @int FROM um_user LIMIT 0,1
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
session里的值,可以在js里直接取值。
${key.value}
------------------------------------------------------
ie下,url含有中文:
var contactPerson=encodeURI(contactPerson);
---------------------------------------------------------
url含有&转义:
contactPerson = contactPerson.replace(/&/g,"%26");
--------------------------------------------------------------
内部类的方法调用外面的变量时,必须是final的。
--------------------------------------------------------------
接口里的方法默认都是public,所以不用写修饰符
---------------------------------------------------------
elipse使用:
//TODO 标记还需要完成的部分。(showview—task)
js代码行号前右键,add task。
---------------------------------------------------------
String idU = UUID.randomUUID().toString();
String id = idU.replaceAll("\\-", "");
-------------------------------------------------------------
奇葩问题:
url中有id字段时,有些框架会字段把值转换成int类型,
如果id字段值长度超过int范围,导致无法跳转
-------------------------------------------------------------
validator.js
-------------------------------------------------------------
sql语句:
SELECT
t.ACTION_URL,
t.HELP_URL,
t.MODULE_CODE
FROM
ts_module t
JOIN ts_role b
ON t.APP_TYPE = b.CREATE_TM
JOIN ts_user c
ON t.ACTION_UR = c.CREATE_TM
WHERE b.CREATE_TM = '2015-03' ;
UPDATE
ts_log t
JOIN ts_role c
ON t.CHANNEL = c.CREATE_TM SET t.AFTER_CHANGE = ''
WHERE t.AFTER_CHANGE = '' ;
DELETE t FROM um_role t JOIN um_user c ON t.CREATE_TIME = c.CREATE_TIME WHERE t.ID = '';
三表联查:
SELECT
*
FROM
(
plf_pur_delivery_notice_detail d
JOIN plf_pur_delivery_plan p
ON d.pur_order_no = p.pur_order_no
AND d.line_item = p.line_item
)
JOIN plf_pur_delivery_notice_main m
ON m.asn_no = d.asn_no
WHERE d.asn_no = 'ASN002'
--------------------------------------------------------------
单表查询:
SELECT
mm.orderNo,
mm.lineItem,
SUM(mm.reAmount)
FROM
(SELECT
b.pur_order_no orderNo,
b.line_item lineItem,
b.reserve_amount reAmount
FROM
plf_pur_delivery_notice_detail b
WHERE CONCAT(b.`pur_order_no`, b.`line_item`) IN
(SELECT
CONCAT(a.`pur_order_no`, a.`line_item`)
FROM
plf_pur_delivery_notice_detail a
WHERE asn_no = 'ASN001'
GROUP BY a.`pur_order_no`,
a.`line_item`)
AND b.suppler_confimr_status = 1) mm
GROUP BY mm.orderNo,
mm.lineItem ;
-----------------------------------------------------------------------------------------------
复杂查询:
SELECT
a.pur_order_no,
a.line_item,
a.material_code,
a.unit,
a.delivery_warehouse_code,
a.promise_delivery_time,
b.material_name,a.promise_delivery_amount,
IFNULL(d.reserve_amount,0)
FROM
plf_pur_delivery_plan a
LEFT JOIN plf_pur_material_data b
ON a.material_code = b.material_code
LEFT JOIN
(SELECT
a.pur_order_no,
a.line_item,
SUM(c.reserve_amount) reserve_amount
FROM
plf_pur_delivery_plan a
INNER JOIN plf_pur_delivery_notice_detail c
ON a.pur_order_no = c.pur_order_no
AND a.line_item = c.line_item
WHERE c.suppler_confimr_status = 1
GROUP BY a.pur_order_no, a.line_item ) d
ON a.pur_order_no = d.pur_order_no
AND a.line_item = d.line_item WHERE
a.promise_delivery_amount > IFNULL(d.reserve_amount,0)
AND a.promise_delivery_time = '2015-10-22'
AND a.pur_order_no = 'order002' AND a.line_item='line3'
------------------------------------------------------------------------------------------
使用right join强制生成一条记录。
SELECT
IFNULL(SUM(k.received_amount), 0) sumAmount
FROM
(SELECT
*
FROM
(SELECT
i.pur_order_no,
i.line_item,
i.received_amount
FROM
plf_pur_delivery_notice_detail i
WHERE i.pur_order_no = 'order002'
AND i.line_item = 'line3') d
GROUP BY d.pur_order_no,
d.line_item) k RIGHT JOIN (SELECT 1 AS c FROM DUAL ) t ON t.c = k.line_item;
--------------------------------------------------------------------------------------
关联查
SELECT
*
FROM
(SELECT
p.id,
p.pur_order_no,
p.line_item,
p.delivery_warehouse_code,
p.supplier_code,
s.name1
FROM
plf_pur_delivery_plan p
LEFT JOIN plf_pur_supplierinfo s
ON p.supplier_code = s.supp_code) pp
LEFT JOIN plf_warehouse_master_data w
ON pp.delivery_warehouse_code = w.whouse_code
WHERE pp.id = '7b091f958d0611e5b82e333018d85ce0'
-------------------------------------------------------------------------------------
mybatis判断字符串相等,必须这样:
妈蛋,
<if test='auditStatus == "1"'>
m.audit_status = '1', m.warehouse_remark = #{warehouseRemark}
</if>
---------------------------------------------------------------12USD
java日历:
SimpleDateFormat sdf=new SimpleDateFormat("yyyy-MM");
Date date=sdf.parse(map.get("quantityTime"));
Calendar cal = Calendar.getInstance();
cal.setTime(date);
cal.set(cal.DATE, 1);
Date dateStart = cal.getTime();
cal.set(cal.DATE, cal.getActualMaximum(cal.DATE));
Date dateEnd = cal.getTime();
-------------------------
jpgrid:
sortname:'id',
sortorder:"desc",
---------------------------------------
mysql:
获取年和月: DATE_FORMAT(quantity_time,'%Y-%m');
-----------------------
修改工程名:修改下面的两个build文件。
1.D:\zkwork\workspace\novatar-tax
2.D:\zkwork\workspace\novatar-tax\project\novatar-webapp
3.D:\zkwork\workspace\novatar-syn\settings
生成war包路径:gradle-build:D:\zkwork\workspace\novatar-tax\build\dist
-------------------------------------------------------------------------------
artdialog/jpgrid两个插件
--------------------------------------------------------------------------------
MySQL主机IP:10.202.4.48(mysql: jeffrey/init1234 jeffrey@10.118.12.23)
Jetty主机IP:10.202.10.31
sfapp/sf123456登录 再切换到 root/sf123456789
su - root;
cd /dba;
cd mysqlhome/;
cd 5.6.21/;
cd bin;
./mysql --socket=/tmp/mysqld_mysqldev.sock --port=3306 -uroot -pmysqldev;
-------------------------------------------------------------------------------------------------------------------
create database `mysqldb`character set utf8 collate utf8_general_ci;
GRANT SELECT,INSERT,UPDATE,DELETE,CREATE,DROP,ALTER ON mysqldb.* TO tiger@10.202.4.48 IDENTIFIED BY 'sf987654321';
SET PASSWORD FOR tiger@10.202.4.48 = OLD_PASSWORD('sf987654321');
desc mysql.user
show grants for jeffrey@'%';
SELECT USER();
SELECT DATABASE();
---------------------------------------------
Linus 命令:su - root
/根目录;
./当前目录;
../上一级目录;
cd .. 返回上一级;
cd directory;
nano filename.txt;(Ctrl+x 退出)
-----------------------------------------------
---------------------------------------------
grant all on *.* to jeffrey@%;(任意地址)
flush privileges;
----------------------------------------------------------------
Last login: Mon Sep 14 20:24:15 2015 from 10.118.12.4
WARNING: If you are not authorized to access this private computer system, disconnect now. All activities on this system will be monitored and recorded without prior notification or permission!
[sfapp@cnsz22vl0273:/home/sfapp]$su - root
Password:
su: incorrect password
[sfapp@cnsz22vl0273:/home/sfapp]$su - root
Password:
**************************************************************************
* *
*Attention: Auditing process will report your every action! *
*Warning: Don't delete any files in directory /root/slogs!! *
* *
* --SF-Express COMPANY OF CHINA,LTD.*
**************************************************************************
Script started, file is /root/slogs/2015-09-15_09:25:46pts-0sfapp.log
[root@cnsz22vl0273:/root]#cd /dba
[root@cnsz22vl0273:/dba]#ll
total 293172
-rwxr-xr-x 1 root root 7019 Mar 3 2015 install.sh
drwxr-xr-x 3 root root 4096 Mar 3 2015 mariadb
-rw-r--r-- 1 root root 300183709 Mar 3 2015 mariadb-10.0.14-linux-x86_64.tar.gz
drwxr-xr-x 3 mysql mysql 4096 Mar 3 2015 mysqlhome
-rw-r--r-- 1 root root 53 Mar 3 2015 mysql.info
[root@cnsz22vl0273:/dba]#cd mysqlhome/
[root@cnsz22vl0273:/dba/mysqlhome]#ll
total 32240
drwxr-xr-x 40 mysql mysql 4096 Mar 3 2015 5.6.21
-rw-r--r-- 1 mysql mysql 33009070 Mar 3 2015 mysql-5.6.21.tar.gz
[root@cnsz22vl0273:/dba/mysqlhome]#cd 5.6.21/
[root@cnsz22vl0273:/dba/mysqlhome/5.6.21]#ll
total 1008
drwxr-xr-x 2 root root 4096 Mar 3 2015 bin
drwxr-xr-x 2 mysql mysql 4096 Sep 11 2014 BUILD
-rw-r--r-- 1 mysql mysql 142 Sep 11 2014 BUILD-CMAKE
drwxr-xr-x 2 mysql mysql 4096 Sep 11 2014 win
drwxr-xr-x 3 mysql mysql 4096 Mar 3 2015 zlib
[root@cnsz22vl0273:/dba/mysqlhome/5.6.21]#cd bin
[root@cnsz22vl0273:/dba/mysqlhome/5.6.21/bin]#ll
total 496524
-rwxr-xr-x 1 root root 4888439 Mar 3 2015 innochecksum
-rwxr-xr-x 1 root root 1556 Mar 3 2015 msql2mysql
-rwxr-xr-x 1 root root 7672650 Mar 3 2015 myisamchk
-rwxr-xr-x 1 root root 7202611 Mar 3 2015 myisam_ftdump
-rwxr-xr-x 1 root root 7026254 Mar 3 2015 myisamlog
-rwxr-xr-x 1 root root 7305814 Mar 3 2015 myisampack
-rwxr-xr-x 1 root root 4813441 Mar 3 2015 my_print_defaults
-rwxr-xr-x 1 root root 9780974 Mar 3 2015 mysql
-rwxr-xr-x 1 root root 111828 Mar 3 2015 mysqlaccess
[root@cnsz22vl0273:/dba/mysqlhome/5.6.21/bin]#./mysql --socket=/tmp/mysqld_mysqldev.sock --port=3306 -uroot -pmysqldev
Warning: Using a password on the command line interface can be insecure.
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 14
Server version: 5.6.21-log Source distribution
Copyright (c) 2000, 2014, Oracle and/or its affiliates. All rights reserved.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
mysql> grant all on *.* to jeffrey@10.202.4.48;
Query OK, 0 rows affected (0.00 sec)
mysql> show grants for current_user;
+--------------------------------------------------------------------------------------------------------------------------------+
| Grants for root@% |
+--------------------------------------------------------------------------------------------------------------------------------+
| GRANT ALL PRIVILEGES ON *.* TO 'root'@'%' IDENTIFIED BY PASSWORD '*3A2AAB75C0786A84487A6CAA437A392294B05FAD' WITH GRANT OPTION |
+--------------------------------------------------------------------------------------------------------------------------------+
1 row in set (0.00 sec)
mysql>
-------------------------------------------------------------------------------------------------------------------------------------
-----------------------------------------------------------------------------------------------------------------------------
ie安全警告、阻止:
if (file.exists()) {
// 可以为application/x-msdownload或者application/octet-stream
response.setContentType("application/octet-stream; charset=gb2312");
// 设置Content-Disposition头的值为"attachment;filename=文件名"
response.setHeader("Content-Disposition", "attachment;filename="
+ new String(annex.getBytes("gb2312"), "iso-8859-1"));
ServletOutputStream outS = response.getOutputStream();
BufferedInputStream inS = new BufferedInputStream(
new FileInputStream(file));
byte[] buff = new byte[1024];
int len = inS.read(buff, 0, 1024);
while (len != -1) {
outS.write(buff, 0, len);
len = inS.read(buff, 0, 1024);
}
inS.close();
outS.flush();
outS.close();
}
但愿这段代码对你有帮助。。我是用Servlet做的上传下载。。但下载写文件应该是一样的。。
-------------------------------------------------------
teambition:123QAZzxc
-----------------------
测试密码:qwe123456
如果没查到,$.each()会报错。
var accessType = "${access_key.accessType}";
var userName = "${curumuser.username}"; 页面获取当前用户的方法
---------------------------------------------------------
sfuat444@sfuat.com
active.123
--------------------------------------------------------------------------
------------------------------------------------------------------------------------------------------------------------
大型网站技术架构:核心原理与案例分析;redis设计与实现;企业应用架构模式;mangodb;
JAVASCRIPT语言精髓与编程实践;算法导论;java tcp/ip 网络编程;深入理解nginx;HighCharts表格学习
------------------------------------------------------------------------------------------------------------------------
SELECT
*
FROM
reportrules
WHERE CODE IN (
'增值税主表',
'附表一 (本期销售情况明细)',
'附表二 (本期进项税额明细)',
'附表三 (扣除项目明细)',
'附表四 (税额抵减情况表)',
'附表五 (不动产分期抵扣计算表)',
'本期抵扣进项税额结构明细表',
'分配表',
'增值税 (小规模纳税人主表)',
'附列资料'
) ;
-----------------------------------------------------------------------------------------------------
HighCharts:
-----------
spring 声明式事物:
1、ServiceA类为Web层的Action服务
2、Action调用了ServiceA的方法A,而方法A没有声明事务(原因是方法A本身比较耗时而又不需要事务)
3、ServiceA的方法A调用了自己的方法B,而方法B声明了事务,但是方法B的事务声明在这种情况失效了。
4、如果在方法A上也声明事务,则在Action调用方法A时,事务生效,而方法B则自动参与了这个事务。
之所以出现这个问题,是因为:我们使用aop进行代理,当执行proxy类的a方法时,会进行拦截(开启事物),
紧接着逻辑走到target类上a方法,而后调用target类的b方法。此时需要明白,它调用的是target类上的b方法,
而不是proxy类的b方法。要知道,针对方法b的横切逻辑,只植入到了proxy类上的方法b中。所以target类的a方
法中所调用的b方法没有开启事物.
-----------------------------------------------------------------------------------------------------
SELECT
*
FROM
b_ztfi_tax_surtax s
WHERE (
s.TAX_ENT_COL_L,
s.TAX_PAY_SUB,
s.GJAHR,
s.MONAT,
s.TAX_CATE
) IN
(SELECT
TAX_ENT_COL_L,
TAX_PAY_SUB,
GJAHR,
MONAT,
TAX_CATE
FROM
b_ztfi_tax_surtax
GROUP BY TAX_ENT_COL_L,
TAX_PAY_SUB,
GJAHR,
MONAT,
TAX_CATE
HAVING COUNT(1) > 1);
---------------------------------------
[user]
name = 80001092
email = 80001092@sf-express.com
signingkey = pujie@sf44
spring,jvm,多线程,
CALL proc_queryTaxAnalysisReport(
'',
'',
'',
'',
'',
'',
'2016-03-01',
'',
'000021',
'1',
0,
1000
);
lac
----------------
ALTER TABLE p2_desperse_bill
CHANGE CREATE_TIME CREATE_TIME TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
CHANGE UPDATE_TIME UPDATE_TIME TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP;
-------------------------------------------------------------------------------------------------------
ALTER TABLE table_name COMMENT='这是表的注释';
--------------------------------------------------
1、各框架原理,底层;
2、String s=new String("abc);
3、hashMap 底层hash值是怎么存储;
4、4h
excel脚本:
="insert into plf_pur_warehouse_contact(id,factory_code,whouse_code,emp_no,emp_name,emp_tel,emp_email) values(REPLACE(UUID(),'-',''),'"&B2&"','"&D2&"','"&H2&"','"&I2&"','"&J2&"','"&K2&"');"
然后下拉。
-------------------------------------------------------------------------------------
sql:
SET @int = (SELECT MAX(id) FROM um_user)
SELECT @int FROM um_user LIMIT 0,1
------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------
session里的值,可以在js里直接取值。
${key.value}
------------------------------------------------------
ie下,url含有中文:
var contactPerson=encodeURI(contactPerson);
---------------------------------------------------------
url含有&转义:
contactPerson = contactPerson.replace(/&/g,"%26");
--------------------------------------------------------------
内部类的方法调用外面的变量时,必须是final的。
--------------------------------------------------------------
接口里的方法默认都是public,所以不用写修饰符
---------------------------------------------------------
elipse使用:
//TODO 标记还需要完成的部分。(showview—task)
js代码行号前右键,add task。
---------------------------------------------------------
String idU = UUID.randomUUID().toString();
String id = idU.replaceAll("\\-", "");
-------------------------------------------------------------
奇葩问题:
url中有id字段时,有些框架会字段把值转换成int类型,
如果id字段值长度超过int范围,导致无法跳转
-------------------------------------------------------------
validator.js
-------------------------------------------------------------
sql语句:
SELECT
t.ACTION_URL,
t.HELP_URL,
t.MODULE_CODE
FROM
ts_module t
JOIN ts_role b
ON t.APP_TYPE = b.CREATE_TM
JOIN ts_user c
ON t.ACTION_UR = c.CREATE_TM
WHERE b.CREATE_TM = '2015-03' ;
UPDATE
ts_log t
JOIN ts_role c
ON t.CHANNEL = c.CREATE_TM SET t.AFTER_CHANGE = ''
WHERE t.AFTER_CHANGE = '' ;
DELETE t FROM um_role t JOIN um_user c ON t.CREATE_TIME = c.CREATE_TIME WHERE t.ID = '';
三表联查:
SELECT
*
FROM
(
plf_pur_delivery_notice_detail d
JOIN plf_pur_delivery_plan p
ON d.pur_order_no = p.pur_order_no
AND d.line_item = p.line_item
)
JOIN plf_pur_delivery_notice_main m
ON m.asn_no = d.asn_no
WHERE d.asn_no = 'ASN002'
--------------------------------------------------------------
单表查询:
SELECT
mm.orderNo,
mm.lineItem,
SUM(mm.reAmount)
FROM
(SELECT
b.pur_order_no orderNo,
b.line_item lineItem,
b.reserve_amount reAmount
FROM
plf_pur_delivery_notice_detail b
WHERE CONCAT(b.`pur_order_no`, b.`line_item`) IN
(SELECT
CONCAT(a.`pur_order_no`, a.`line_item`)
FROM
plf_pur_delivery_notice_detail a
WHERE asn_no = 'ASN001'
GROUP BY a.`pur_order_no`,
a.`line_item`)
AND b.suppler_confimr_status = 1) mm
GROUP BY mm.orderNo,
mm.lineItem ;
-----------------------------------------------------------------------------------------------
复杂查询:
SELECT
a.pur_order_no,
a.line_item,
a.material_code,
a.unit,
a.delivery_warehouse_code,
a.promise_delivery_time,
b.material_name,a.promise_delivery_amount,
IFNULL(d.reserve_amount,0)
FROM
plf_pur_delivery_plan a
LEFT JOIN plf_pur_material_data b
ON a.material_code = b.material_code
LEFT JOIN
(SELECT
a.pur_order_no,
a.line_item,
SUM(c.reserve_amount) reserve_amount
FROM
plf_pur_delivery_plan a
INNER JOIN plf_pur_delivery_notice_detail c
ON a.pur_order_no = c.pur_order_no
AND a.line_item = c.line_item
WHERE c.suppler_confimr_status = 1
GROUP BY a.pur_order_no, a.line_item ) d
ON a.pur_order_no = d.pur_order_no
AND a.line_item = d.line_item WHERE
a.promise_delivery_amount > IFNULL(d.reserve_amount,0)
AND a.promise_delivery_time = '2015-10-22'
AND a.pur_order_no = 'order002' AND a.line_item='line3'
------------------------------------------------------------------------------------------
使用right join强制生成一条记录。
SELECT
IFNULL(SUM(k.received_amount), 0) sumAmount
FROM
(SELECT
*
FROM
(SELECT
i.pur_order_no,
i.line_item,
i.received_amount
FROM
plf_pur_delivery_notice_detail i
WHERE i.pur_order_no = 'order002'
AND i.line_item = 'line3') d
GROUP BY d.pur_order_no,
d.line_item) k RIGHT JOIN (SELECT 1 AS c FROM DUAL ) t ON t.c = k.line_item;
--------------------------------------------------------------------------------------
关联查
SELECT
*
FROM
(SELECT
p.id,
p.pur_order_no,
p.line_item,
p.delivery_warehouse_code,
p.supplier_code,
s.name1
FROM
plf_pur_delivery_plan p
LEFT JOIN plf_pur_supplierinfo s
ON p.supplier_code = s.supp_code) pp
LEFT JOIN plf_warehouse_master_data w
ON pp.delivery_warehouse_code = w.whouse_code
WHERE pp.id = '7b091f958d0611e5b82e333018d85ce0'
-------------------------------------------------------------------------------------
mybatis判断字符串相等,必须这样:
妈蛋,
<if test='auditStatus == "1"'>
m.audit_status = '1', m.warehouse_remark = #{warehouseRemark}
</if>
---------------------------------------------------------------12USD
java日历:
SimpleDateFormat sdf=new SimpleDateFormat("yyyy-MM");
Date date=sdf.parse(map.get("quantityTime"));
Calendar cal = Calendar.getInstance();
cal.setTime(date);
cal.set(cal.DATE, 1);
Date dateStart = cal.getTime();
cal.set(cal.DATE, cal.getActualMaximum(cal.DATE));
Date dateEnd = cal.getTime();
-------------------------
jpgrid:
sortname:'id',
sortorder:"desc",
---------------------------------------
mysql:
获取年和月: DATE_FORMAT(quantity_time,'%Y-%m');
-----------------------
修改工程名:修改下面的两个build文件。
1.D:\zkwork\workspace\novatar-tax
2.D:\zkwork\workspace\novatar-tax\project\novatar-webapp
3.D:\zkwork\workspace\novatar-syn\settings
生成war包路径:gradle-build:D:\zkwork\workspace\novatar-tax\build\dist
-------------------------------------------------------------------------------
artdialog/jpgrid两个插件
--------------------------------------------------------------------------------
MySQL主机IP:10.202.4.48(mysql: jeffrey/init1234 jeffrey@10.118.12.23)
Jetty主机IP:10.202.10.31
sfapp/sf123456登录 再切换到 root/sf123456789
su - root;
cd /dba;
cd mysqlhome/;
cd 5.6.21/;
cd bin;
./mysql --socket=/tmp/mysqld_mysqldev.sock --port=3306 -uroot -pmysqldev;
-------------------------------------------------------------------------------------------------------------------
create database `mysqldb`character set utf8 collate utf8_general_ci;
GRANT SELECT,INSERT,UPDATE,DELETE,CREATE,DROP,ALTER ON mysqldb.* TO tiger@10.202.4.48 IDENTIFIED BY 'sf987654321';
SET PASSWORD FOR tiger@10.202.4.48 = OLD_PASSWORD('sf987654321');
desc mysql.user
show grants for jeffrey@'%';
SELECT USER();
SELECT DATABASE();
---------------------------------------------
Linus 命令:su - root
/根目录;
./当前目录;
../上一级目录;
cd .. 返回上一级;
cd directory;
nano filename.txt;(Ctrl+x 退出)
-----------------------------------------------
---------------------------------------------
grant all on *.* to jeffrey@%;(任意地址)
flush privileges;
----------------------------------------------------------------
Last login: Mon Sep 14 20:24:15 2015 from 10.118.12.4
WARNING: If you are not authorized to access this private computer system, disconnect now. All activities on this system will be monitored and recorded without prior notification or permission!
[sfapp@cnsz22vl0273:/home/sfapp]$su - root
Password:
su: incorrect password
[sfapp@cnsz22vl0273:/home/sfapp]$su - root
Password:
**************************************************************************
* *
*Attention: Auditing process will report your every action! *
*Warning: Don't delete any files in directory /root/slogs!! *
* *
* --SF-Express COMPANY OF CHINA,LTD.*
**************************************************************************
Script started, file is /root/slogs/2015-09-15_09:25:46pts-0sfapp.log
[root@cnsz22vl0273:/root]#cd /dba
[root@cnsz22vl0273:/dba]#ll
total 293172
-rwxr-xr-x 1 root root 7019 Mar 3 2015 install.sh
drwxr-xr-x 3 root root 4096 Mar 3 2015 mariadb
-rw-r--r-- 1 root root 300183709 Mar 3 2015 mariadb-10.0.14-linux-x86_64.tar.gz
drwxr-xr-x 3 mysql mysql 4096 Mar 3 2015 mysqlhome
-rw-r--r-- 1 root root 53 Mar 3 2015 mysql.info
[root@cnsz22vl0273:/dba]#cd mysqlhome/
[root@cnsz22vl0273:/dba/mysqlhome]#ll
total 32240
drwxr-xr-x 40 mysql mysql 4096 Mar 3 2015 5.6.21
-rw-r--r-- 1 mysql mysql 33009070 Mar 3 2015 mysql-5.6.21.tar.gz
[root@cnsz22vl0273:/dba/mysqlhome]#cd 5.6.21/
[root@cnsz22vl0273:/dba/mysqlhome/5.6.21]#ll
total 1008
drwxr-xr-x 2 root root 4096 Mar 3 2015 bin
drwxr-xr-x 2 mysql mysql 4096 Sep 11 2014 BUILD
-rw-r--r-- 1 mysql mysql 142 Sep 11 2014 BUILD-CMAKE
drwxr-xr-x 2 mysql mysql 4096 Sep 11 2014 win
drwxr-xr-x 3 mysql mysql 4096 Mar 3 2015 zlib
[root@cnsz22vl0273:/dba/mysqlhome/5.6.21]#cd bin
[root@cnsz22vl0273:/dba/mysqlhome/5.6.21/bin]#ll
total 496524
-rwxr-xr-x 1 root root 4888439 Mar 3 2015 innochecksum
-rwxr-xr-x 1 root root 1556 Mar 3 2015 msql2mysql
-rwxr-xr-x 1 root root 7672650 Mar 3 2015 myisamchk
-rwxr-xr-x 1 root root 7202611 Mar 3 2015 myisam_ftdump
-rwxr-xr-x 1 root root 7026254 Mar 3 2015 myisamlog
-rwxr-xr-x 1 root root 7305814 Mar 3 2015 myisampack
-rwxr-xr-x 1 root root 4813441 Mar 3 2015 my_print_defaults
-rwxr-xr-x 1 root root 9780974 Mar 3 2015 mysql
-rwxr-xr-x 1 root root 111828 Mar 3 2015 mysqlaccess
[root@cnsz22vl0273:/dba/mysqlhome/5.6.21/bin]#./mysql --socket=/tmp/mysqld_mysqldev.sock --port=3306 -uroot -pmysqldev
Warning: Using a password on the command line interface can be insecure.
Welcome to the MySQL monitor. Commands end with ; or \g.
Your MySQL connection id is 14
Server version: 5.6.21-log Source distribution
Copyright (c) 2000, 2014, Oracle and/or its affiliates. All rights reserved.
Oracle is a registered trademark of Oracle Corporation and/or its
affiliates. Other names may be trademarks of their respective
owners.
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
mysql> grant all on *.* to jeffrey@10.202.4.48;
Query OK, 0 rows affected (0.00 sec)
mysql> show grants for current_user;
+--------------------------------------------------------------------------------------------------------------------------------+
| Grants for root@% |
+--------------------------------------------------------------------------------------------------------------------------------+
| GRANT ALL PRIVILEGES ON *.* TO 'root'@'%' IDENTIFIED BY PASSWORD '*3A2AAB75C0786A84487A6CAA437A392294B05FAD' WITH GRANT OPTION |
+--------------------------------------------------------------------------------------------------------------------------------+
1 row in set (0.00 sec)
mysql>
-------------------------------------------------------------------------------------------------------------------------------------
-----------------------------------------------------------------------------------------------------------------------------
ie安全警告、阻止:
if (file.exists()) {
// 可以为application/x-msdownload或者application/octet-stream
response.setContentType("application/octet-stream; charset=gb2312");
// 设置Content-Disposition头的值为"attachment;filename=文件名"
response.setHeader("Content-Disposition", "attachment;filename="
+ new String(annex.getBytes("gb2312"), "iso-8859-1"));
ServletOutputStream outS = response.getOutputStream();
BufferedInputStream inS = new BufferedInputStream(
new FileInputStream(file));
byte[] buff = new byte[1024];
int len = inS.read(buff, 0, 1024);
while (len != -1) {
outS.write(buff, 0, len);
len = inS.read(buff, 0, 1024);
}
inS.close();
outS.flush();
outS.close();
}
但愿这段代码对你有帮助。。我是用Servlet做的上传下载。。但下载写文件应该是一样的。。
-------------------------------------------------------
teambition:123QAZzxc
-----------------------
测试密码:qwe123456
如果没查到,$.each()会报错。
var accessType = "${access_key.accessType}";
var userName = "${curumuser.username}"; 页面获取当前用户的方法
---------------------------------------------------------
sfuat444@sfuat.com
active.123
--------------------------------------------------------------------------
------------------------------------------------------------------------------------------------------------------------
大型网站技术架构:核心原理与案例分析;redis设计与实现;企业应用架构模式;mangodb;
JAVASCRIPT语言精髓与编程实践;算法导论;java tcp/ip 网络编程;深入理解nginx;HighCharts表格学习
------------------------------------------------------------------------------------------------------------------------
SELECT
*
FROM
reportrules
WHERE CODE IN (
'增值税主表',
'附表一 (本期销售情况明细)',
'附表二 (本期进项税额明细)',
'附表三 (扣除项目明细)',
'附表四 (税额抵减情况表)',
'附表五 (不动产分期抵扣计算表)',
'本期抵扣进项税额结构明细表',
'分配表',
'增值税 (小规模纳税人主表)',
'附列资料'
) ;
-----------------------------------------------------------------------------------------------------
HighCharts:
-----------
spring 声明式事物:
1、ServiceA类为Web层的Action服务
2、Action调用了ServiceA的方法A,而方法A没有声明事务(原因是方法A本身比较耗时而又不需要事务)
3、ServiceA的方法A调用了自己的方法B,而方法B声明了事务,但是方法B的事务声明在这种情况失效了。
4、如果在方法A上也声明事务,则在Action调用方法A时,事务生效,而方法B则自动参与了这个事务。
之所以出现这个问题,是因为:我们使用aop进行代理,当执行proxy类的a方法时,会进行拦截(开启事物),
紧接着逻辑走到target类上a方法,而后调用target类的b方法。此时需要明白,它调用的是target类上的b方法,
而不是proxy类的b方法。要知道,针对方法b的横切逻辑,只植入到了proxy类上的方法b中。所以target类的a方
法中所调用的b方法没有开启事物.
-----------------------------------------------------------------------------------------------------
SELECT
*
FROM
b_ztfi_tax_surtax s
WHERE (
s.TAX_ENT_COL_L,
s.TAX_PAY_SUB,
s.GJAHR,
s.MONAT,
s.TAX_CATE
) IN
(SELECT
TAX_ENT_COL_L,
TAX_PAY_SUB,
GJAHR,
MONAT,
TAX_CATE
FROM
b_ztfi_tax_surtax
GROUP BY TAX_ENT_COL_L,
TAX_PAY_SUB,
GJAHR,
MONAT,
TAX_CATE
HAVING COUNT(1) > 1);
---------------------------------------
[user]
name = 80001092
email = 80001092@sf-express.com
signingkey = pujie@sf44
spring,jvm,多线程,
CALL proc_queryTaxAnalysisReport(
'',
'',
'',
'',
'',
'',
'2016-03-01',
'',
'000021',
'1',
0,
1000
);
lac
----------------
ALTER TABLE p2_desperse_bill
CHANGE CREATE_TIME CREATE_TIME TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
CHANGE UPDATE_TIME UPDATE_TIME TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP;
-------------------------------------------------------------------------------------------------------
ALTER TABLE table_name COMMENT='这是表的注释';
--------------------------------------------------
1、各框架原理,底层;
2、String s=new String("abc);
3、hashMap 底层hash值是怎么存储;
4、4h
相关推荐
Java版记事本是一款完全由Java编程语言编写的文本编辑器,主要利用了Java Swing库来构建用户界面。Swing是Java的一个图形用户界面(GUI)工具包,它为开发者提供了丰富的组件,使得创建桌面应用程序变得更为简单。这个...
"Asp.net C# 创建记事本,并给记事本输入文字"这个项目就是这样的一个实例,它展示了如何通过C#调用Windows API来创建一个记事本程序,并向其中写入文本。 首先,让我们了解什么是Windows API。Windows API是微软为...
在C++编程中,创建、打开并写入记事本文件是一种常见的操作,尤其是在学习文件I/O时。这里我们将详细探讨如何使用C++实现这个功能,并通过`system()`函数调用操作系统命令来显示记事本,查看写入的数据。首先,我们...
在Android平台上开发一款记事本应用,涉及到许多关键知识点,这些知识点构成了移动应用开发的基础。以下将详细解析这些核心概念: 1. **Android操作系统**:Android是Google开发的一款开源操作系统,广泛应用于智能...
在这个“易语言打开记事本并写入内容”的主题中,我们将探讨如何利用易语言来实现这样的功能,包括打开系统自带的记事本程序并向其中写入特定的内容。 首先,我们要理解易语言中的几个关键概念。`取得窗口_`是...
在本文中,我们将深入探讨如何使用QT框架来创建一个简单的基于Windows的记事本应用程序。QT是一个跨平台的C++库,它提供了丰富的图形用户界面(GUI)工具和功能,使得开发人员能够轻松构建各种类型的应用程序,包括...
**MFC简单记事本程序**是基于Microsoft Foundation Class (MFC)库开发的一个基础文本编辑应用程序,适用于学习和理解MFC编程。MFC是微软为Windows平台提供的一套C++类库,它封装了Windows API,使得开发者可以更方便...
《密码记事本:安全存储的秘密武器》 在数字化时代,个人信息的安全日益受到重视,而密码作为保护我们数字资产的第一道防线,其管理和保存显得尤为重要。"密码记事本"是一款专为此目的设计的汉化版软件,它将传统的...
【标题】"JAVA编写的日历记事本 实现日历及记事本功能" 描述了一款基于Java编程语言开发的应用程序,该程序集成了日历和记事本两大功能。在Java中,这样的应用通常涉及到GUI(图形用户界面)设计、事件处理以及数据...
【标题】"java记事本 源代码"所涉及的知识点主要集中在Java编程语言、图形用户界面(GUI)设计以及文件操作上。这个项目利用Java的Swing库来构建一个类似于Windows记事本的应用程序,它实现了文本编辑的基础功能。 ...
【标题】"记事本编写的贪吃蛇"是一款基于文本界面的小游戏,它通过简单的命令行输出在记事本中实现。贪吃蛇游戏的基本原理是控制一个由字符表示的蛇在有限的网格内移动,吃到食物后增长,同时避免撞到自身或边界。 ...
【标题】"漂亮的完整记事本 功能齐全 源码"所指的是一款设计美观且功能丰富的记事本软件,这款软件不仅在界面设计上追求美观,而且提供了多种实用的功能,满足用户日常的文本编辑需求。作为一个.NET程序,它可以被...
在Android平台上,开发一个记事本程序涉及到许多关键知识点,这些知识点主要涵盖用户界面(UI)设计、数据存储以及应用程序的逻辑结构。本项目“Android记事本程序代码”提供了一个学习和实践这些技能的机会。 首先...
JAVA手机记事本,是很好用的JAVA手机记事本,VVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVVV。经验证,金立手机L18可用。JAVA手机记事本,是很好用的JAVA手机记事本,...
记事本程序是计算机操作系统中常见的一种简单文本编辑器,它允许用户创建、查看和编辑纯文本文件。在Windows操作系统中,内置的记事本应用(Notepad)因其简洁的界面和基本的文本处理功能而广受欢迎。这个压缩包文件...
【Qt版简易记事本】是一款基于Qt框架开发的简单文本编辑器,主要适用于学习Qt编程的初学者。Qt是一个跨平台的C++图形用户界面应用程序开发框架,它提供了丰富的API和工具,使得开发者能够在Windows、Linux、Mac OS等...
### 右键添加新建记事本 在日常工作中,我们经常需要快速创建文本文件来记录信息或进行简单编辑。在Windows系统中,默认情况下,我们可以通过右键菜单中的“新建”选项来快速创建记事本文件(.txt)。然而,有时...
标题中的"C#记事本(模仿系统记事本写的)"是指使用C#编程语言开发的一个文本编辑器程序,它的设计灵感来源于操作系统自带的记事本应用程序。开发者试图通过这个项目来实现与系统记事本相同的功能,以供初学者学习和...
"易语言打开记事本并写入内容源码"是一个基础的程序示例,它展示了如何使用易语言与操作系统进行交互,控制外部应用程序,如记事本,并向其写入数据。下面我们将详细讨论这个知识点。 首先,易语言提供了丰富的系统...
标题 "一个用VB写的类似Windows的记事本" 暗示了这是一个使用Visual Basic (VB) 开发的文本编辑器程序,它模仿了Windows操作系统自带的记事本应用程序,并在设计和功能上有所增强。VB是Microsoft开发的一种面向对象...