java excel read sample

import java.io.FileInputStream; import java.util.ArrayList; import java.util.List; import org.apache.poi.hssf.usermodel.HSSFSheet; import org.apache.poi.hssf.usermodel.HSSFWorkbook; import org.apache.poi.ss.usermodel.Cell; import org.apach…

postgresql trick by generate_series

select * from GENERATE_SERIES('2020-03-12'::timestamp, '2030-03-12'::timestamp, '6 month'::INTERVAL); generate_series --------------------- 2020-03-12 00:00:00 2020-09-12 00:00:00 2021-03-12 00:00:00 2021-09-12 00:00:00 2022-03-12 00:00:00…

BIRT decimal - float

ref: bugs.eclipse.org and test below: exam

compare db postgres

hacknote.jp

thanks helps

tmftake.hateblo.jp

dbunt - apache poi export excel date type format helps me

shorindo.com

found

qiita.com

my memo ( jspc )

www.ne.jp

hudson war lib

mvnrepository.com

birt add dynamic where clause to dataset query

1. query 2. dynamic where clause(if parameter in)

increase rows in count column : generate_series function

luna=# select * from sample; stake_no | cnt ----------+----- 0001 | 1 0002 | 3 (2 rows) luna=# select * from sample,generate_series(1, 99) as id where sample.cnt >= id; stake_no | cnt | id ----------+-----+---- 0001 | 1 | 1 0002 | 3 | 1 00…

postgresql - jdbc driver compatibility

jdbc.postgresql.org

bird archive site

archive.eclipse.org

easy mock nested sample

<test class> 1. inner class public class ConcatorIml implements Concater { @Override public String concat(String str1, String str2) throws Exception { String conc = ""; conc = str1+str2; return conc; } } 2.outer class public class parConcatorImpl impl</test>…

spring aop example in spring✖️struts

Intercepter import org.aopalliance.intercept.MethodInterceptor; import org.aopalliance.intercept.MethodInvocation; public class MyMethodIntercepter implements MethodInterceptor { @Override public Object invoke(MethodInvocation invocation) …

spring-ibatis sql log setting

log4j.rootCategory=INFO, consoleLog log4j.category.jp.terasoluna=DEBUG log4j.category.org.springframework=INFO log4j.category.org.apache.struts=INFO log4j.category.java.sql.Connection= DEBUG log4j.category.java.sql.Statement= DEBUG log4j.c…

old "STS" download

http://dist.springsource.com/release/STS/index.html

jenkins on Mac OS X

homebrewでインストールした際、初回起動時にanonymous以外のユーザが 未作成にも関わらず、ログインを求められる。 ネット上にはパスワードファイルを確認するように書かれているが、そもそも ユーザアカウントが一つもないのでパスワードファイルなどない…

apache axis

WebServices - Axis

log4j to console

log4j.rootCategory=INFO, consoleLog log4j.category.jp.terasoluna=DEBUG log4j.category.org.springframework=INFO log4j.category.org.apache.struts=INFO log4j.appender.consoleLog=org.apache.log4j.ConsoleAppender log4j.appender.consoleLog.Targe…

jquery updrafts

jqueryui.com

using Set not to duplicate values

sample code below package homeWork; import java.util.ArrayList; import java.util.HashMap; import java.util.HashSet; import java.util.List; import java.util.Map; import java.util.Set; public class distinctSample2 { public static void main(S…

how stream().distinct() works - list of maps

sample code below: package homeWork; import java.util.ArrayList; import java.util.HashMap; import java.util.List; import java.util.Map; import java.util.stream.Collectors; public class distinctSample { public static void main(String[] args…

awk like sql

1)sample data tk-no-MacBook-Pro:~ tk$ cat test.csv 01,8888888,9999999999 09,7777777,6666666666 02,2777333,9999992222 03,8888888,6567637476 2)select col2,col3 from ... where col1 = 09 tk-no-MacBook-Pro:~ tk$ awk -F, '{if ($1 == 09) print $2…

how to grouping and maxBy (list of maps)

1) list of maps : sample list of maps 2) grouping and maxBy main codes 3) before and results appendix) to copy List<Optional<Map<String, Object>>> aggrList = mockList.stream().collect(Collectors.groupingBy(p -> (String)p.get("niveau_1")+ (String)p.get("niveau_2")+(Str</optional<map<string,>…

spring batch : junit test sample

1.project files are below(use terasolua spring batch sample) 2.test codes(test class) package batch; import static org.junit.Assert.fail; import org.junit.Test; import org.junit.runner.RunWith; import org.junit.runners.JUnit4; import org.s…

its util

ttps://www.atmarkit.co.jp/ait/articles/0704/20/news130.html

ls with timestamp (BSD ver.)

ls -l below tk-no-MacBook-Pro:webapps tk$ ls -l total 51584 drwxr-xr-x@ 10 tk staff 340 1 29 2008 ROOT drwxr-xr-x@ 5 tk staff 170 1 29 2008 balancer drwxr-xr-x@ 23 tk staff 782 1 29 2008 jsp-examples drwxr-xr-x@ 11 tk staff 374 1 29 2008 s…

thanks for ...

https://gonsuke777.hatenablog.com/entry/20170112/1484215308

sts old dw

sts(spring tools suite) legacy download below https://spring.io/tools3/sts/legacy