728x90
๋ฐ˜์‘ํ˜•

์ „์ฒด ๊ธ€ 1364

[DB][Oracle] ๋‚ ์งœ+์‹œ๊ฐ„ ๋ฌธ์ž์—ด๊ณผ ๋‚ ์งœ๋ฌธ์ž์—ด ๋น„๊ตํ•˜๊ธฐ

์˜ค๋ผํด์—์„œ RQ1_DT์™€ RQ1_TM์„ ๋‚ ์งœ ํ˜•์‹์œผ๋กœ ๋ณ€ํ™˜ํ•œ ํ›„ ๊ฒฐํ•ฉํ•˜๊ณ , CMP_REQ_DT์™€ ๋™์ผํ•œ ํ˜•์‹์œผ๋กœ ๋น„๊ตํ•˜๊ธฐ ์œ„ํ•ด TO_DATE ํ•จ์ˆ˜๋ฅผ ์‚ฌ์šฉํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.RQ1_DT์™€ RQ1_TM์€ ๊ฐ๊ฐ YYYYMMDD์™€ HH24MI ํ˜•์‹์˜ ๋ฌธ์ž์—ด์ด๋ฏ€๋กœ, ์ด๋ฅผ TO_DATE๋กœ ๋ณ€ํ™˜ํ•˜์—ฌ ๋‚ ์งœ์™€ ์‹œ๊ฐ„์„ ํฌํ•จํ•œ ํ˜•์‹์œผ๋กœ ๋งŒ๋“ญ๋‹ˆ๋‹ค.CMP_REQ_DT๋Š” ๋‚ ์งœ ์ •๋ณด๋งŒ ํฌํ•จํ•˜๋ฏ€๋กœ ์ด๋ฅผ TO_DATE๋กœ ๋ณ€ํ™˜ํ•˜์—ฌ ์ผ๊ด€์„ฑ ์žˆ๊ฒŒ ์ฒ˜๋ฆฌํ•ฉ๋‹ˆ๋‹ค.SELECT '์„ค์น˜' AS ๋ถ„๋ฅ˜, EO_RQ_TP AS ์š”์ฒญ์œ ํ˜•, CUST_CD, CT.CUST_NM AS ๊ณ ๊ฐ์‚ฌ, CR_CD, CR.CR_SCD AS ๊ณ ๊ฐ๋ฒˆํ˜ธ, EO_STAT_TP AS ์š”์ฒญ์ƒํƒœ, TO_DATE(RQ1_DT || RQ1_TM, ..

DB 2024.10.22

[JAVA] ๋ฐฐ์—ด์ƒ์„ฑ - ๊ธธ์ด์ง€์ •

Java์—์„œ ๋ฐฐ์—ด์€ ๋ฐ˜๋“œ์‹œ ๊ณ ์ •๋œ ๊ธธ์ด๋ฅผ ์ง€์ •ํ•ด์•ผ ํ•ฉ๋‹ˆ๋‹ค.๋ฐฐ์—ด์˜ ๊ธธ์ด๋ฅผ ์ง€์ •ํ•˜์ง€ ์•Š์œผ๋ฉด ์ปดํŒŒ์ผ ์˜ค๋ฅ˜๊ฐ€ ๋ฐœ์ƒํ•ฉ๋‹ˆ๋‹ค.์˜ˆ๋ฅผ ๋“ค์–ด ๋‹ค์Œ ์ฝ”๋“œ๋Š” ์˜ค๋ฅ˜๋ฅผ ๋ฐœ์ƒ์‹œํ‚ต๋‹ˆ๋‹ค:Long[] longObjArray = new Long[]; // ์ปดํŒŒ์ผ ์˜ค๋ฅ˜

JAVA 2024.10.21

[JAVA] List์˜ ํŠน์ •๊ฐ’์œผ๋กœ Long[] ๋ฐฐ์—ด ๋งŒ๋“ค๊ธฐ

import java.util.List;import java.util.stream.Collectors;public class Main { public static void main(String[] args) { // ์˜ˆ์‹œ๋กœ updateParams ๊ฐ์ฒด์™€ getCrItems() ๋ฆฌ์ŠคํŠธ๋ฅผ ๊ฐ€์ • UpdateParams updateParams = new UpdateParams(); // getCrItems()๊ฐ€ List๋ฅผ ๋ฐ˜ํ™˜ํ•œ๋‹ค๊ณ  ๊ฐ€์ • List crItems = updateParams.getCrItems(); // getIDx()๋ฅผ ์‚ฌ์šฉํ•˜์—ฌ ๊ฐ CrItem์—์„œ IDx ๊ฐ’์„ ์ถ”์ถœํ•˜๊ณ  Long ๋ฐฐ์—ด๋กœ ๋ณ€ํ™˜ ..

JAVA 2024.10.20

[Error][Mybatis] ArrayIndexOutOfBoundsException

๋นˆ ๋ฐฐ์—ด ๋˜๋Š” ๋ฆฌ์ŠคํŠธ๋ฅผ ์ฒ˜๋ฆฌํ•˜๋Š” ๋ฐฉ๋ฒ•์€ ์กฐ๊ฑด๋ฌธ์—์„œ ์ถ”๊ฐ€๋กœ ์ฒดํฌ๋ฅผ ํ†ตํ•ด ๋ฐฐ์—ด์˜ ํฌ๊ธฐ๋ฅผ ํ™•์ธํ•˜๋Š” ๊ฒƒ์ž…๋‹ˆ๋‹ค.Java ๋ฐฐ์—ด์€ length์†์„ฑ์„ ์‚ฌ์šฉํ•ฉ๋‹ˆ๋‹ค.param.opClsTp.length > 0๋กœ ๋ฐฐ์—ด์ด ๋น„์–ด ์žˆ์ง€ ์•Š์€์ง€ ํ™•์ธํ•ฉ๋‹ˆ๋‹ค.๋ฐฐ์—ด์ด ๋น„์–ด ์žˆ์ง€ ์•Š์œผ๋ฉด ์ฒซ ๋ฒˆ์งธ ์š”์†Œ๋ฅผ ์ œ์™ธํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค. 0 and param.opClsTp[0].equalsIgnoreCase('2')"> AND OPH.HOLD_TP = #{param.opDestroyTp} 0 and param.opClsTp[0].equalsIgnoreCase('3')"> AND OPD.DROP_TP = #{param.opDestroyTp} 0 and param.opClsTp[0].equals..

Error 2024.10.19

[Error][MyBatis] org.apache.ibatis.builder.BuilderException: Error evaluating expression

org.mybatis.spring.MyBatisSystemException:nested exception is org.apache.ibatis.builder.BuilderException: Error evaluating expression ' != null and param.opFailTp.equalsIgnoreCase('Y')'. Cause: org.apache.ibatis.ognl.ExpressionSyntaxException:Malformed OGNL expression: != null and param.opFailTp.equalsIgnoreCase('Y') [org.apache.ibatis.ognl.ParseException: Encountered " "!=" "!= "" at line 1, co..

Error 2024.10.18

[Error][Mybatis]org.xml.sax.SAXParseException:

1. ํŠน์ˆ˜ ๋ฌธ์ž ๋˜๋Š” ์ด์Šค์ผ€์ดํ”„๋˜์ง€ ์•Š์€ ๊ธฐํ˜ธ:&XML์€ , , ', ์™€ ๊ฐ™์€ ํŠน์ˆ˜ ๋ฌธ์ž๋ฅผ ์ธ์‹ํ•ฉ๋‹ˆ๋‹ค ".ํŠน์ˆ˜ ๋ฌธ์ž๊ฐ€ ์ด์Šค์ผ€์ดํ”„๋˜๊ฑฐ๋‚˜ ์˜ฌ๋ฐ”๋ฅด๊ฒŒ ์‚ฌ์šฉ๋˜์—ˆ๋Š”์ง€ ํ™•์ธํ•˜์„ธ์š”.์˜ˆ๋ฅผ ๋“ค์–ด, ๊ธฐํ˜ธ๊ฐ€ ์žˆ๋Š” ๊ฒฝ์šฐ &๋‹ค์Œ๊ณผ ๊ฐ™์ด ์ž‘์„ฑํ•ด์•ผ ํ•ฉ๋‹ˆ๋‹ค &.2. ์˜ฌ๋ฐ”๋ฅธ ํƒœ๊ทธ ๋‹ซํž˜:๋ชจ๋“  XML ํƒœ๊ทธ๊ฐ€ ์ œ๋Œ€๋กœ ์—ด๋ฆฌ๊ณ  ๋‹ซํ˜”๋Š”์ง€ ํ™•์ธํ•˜์„ธ์š”. ๋ชจ๋“  ํƒœ๊ทธ ์—๋Š” ํ•ด๋‹น .์ด ์žˆ์–ด์•ผ ํ•ฉ๋‹ˆ๋‹ค .3. CDATA ์„น์…˜(ํ•„์š”ํ•œ ๊ฒฝ์šฐ):SQL ์ฟผ๋ฆฌ์— ํŠน์ˆ˜ ๋ฌธ์ž๋ฅผ ํฌํ•จํ•˜๊ณ  ํ•ด๋‹น ๋ฌธ์ž๊ฐ€ XML๋กœ ํ•ด์„๋˜์ง€ ์•Š๋„๋ก ํ•˜๋Š” ๊ฒฝ์šฐ CDATA ๋ธ”๋ก ์•ˆ์— ํŠน์ˆ˜ ๋ฌธ์ž๋ฅผ ๋ฌถ์Šต๋‹ˆ๋‹ค.  4. ๋™์  SQL ์กฐ๊ฐ:๋ชจ๋“  ๋™์  SQL ์š”์†Œ( , , , ๋“ฑ)๊ฐ€ ์˜ฌ๋ฐ”๋ฅด๊ฒŒ ๊ตฌ์„ฑ๋˜๊ณ  ์ œ๋Œ€๋กœ ๋‹ซํ˜”๋Š”์ง€ ํ™•์ธํ•˜์„ธ์š”.5. ๋งค๊ฐœ๋ณ€์ˆ˜ ์ž๋ฆฌ ํ‘œ์‹œ์ž:์ฟผ๋ฆฌ์—์„œ ๋งค๊ฐœ๋ณ€์ˆ˜ ์‚ฌ์šฉ์— ์‹ค์ˆ˜( #{}, ) ๊ฐ€ ..

Error 2024.10.17

[DB][SQL] 01์›” ~ 12์›” ๋ฐ์ดํ„ฐ๊ฐ€ ์—†์–ด๋„ ์กฐํšŒํ•˜๊ธฐ

WITH months AS ( -- Generate the list of months from 01 to 12 for the given year (e.g., 2024) SELECT LPAD(LEVEL, 2, '0') AS month FROM dual CONNECT BY LEVEL  T_PRICE ํ…Œ์ด๋ธ”์— 1์›” ~ 12์›” ๊นŒ์ง€์˜ ๋ฐ์ดํ„ฐ๊ฐ€ ์ „๋ถ€ ์žˆ๋Š”๊ฒŒ ์•„๋‹ˆ์—ฌ๋„ 1์›” ~ 12์›” ๋ฆฌ์ŠคํŠธ ์กฐํšŒ๋œ๋‹ค.PRC์ปฌ๋Ÿผ์— ๊ฐ’์ด ์—†์–ด๋„ 0์œผ๋กœ ์กฐํšŒ๋œ๋‹ค.

DB 2024.10.16

[HTML] autocomplete="off"๋ฅผ ์‚ฌ์šฉํ•˜๋Š” ์ด์œ 

๋ฏผ๊ฐํ•œ ์ •๋ณด : ๋ฏผ๊ฐํ•œ ๋ฐ์ดํ„ฐ(์˜ˆ: ๋น„๋ฐ€๋ฒˆํ˜ธ, ์‹ ์šฉ์นด๋“œ ๋ฒˆํ˜ธ, ๊ฐœ์ธ ์ •๋ณด)๋ฅผ ์ฒ˜๋ฆฌํ•˜๋Š” ํ•„๋“œ์˜ ๊ฒฝ์šฐ ๋ณด์•ˆ์„ ๊ฐ•ํ™”ํ•˜๊ธฐ ์œ„ํ•ด ๋ธŒ๋ผ์šฐ์ €๊ฐ€ ๊ฐ’์„ ์ €์žฅํ•˜๊ณ  ์ž๋™์œผ๋กœ ์ฑ„์šฐ๋Š” ๊ฒƒ์„ ๋ฐฉ์ง€ํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค. input type="password" autocomplete="off"> ๋™์  ์–‘์‹์—์„œ ์ž๋™ ์ฑ„์šฐ๊ธฐ ๋ฐฉ์ง€ : ๋™์  ๋˜๋Š” ๋ฐ˜๋ณต ์–‘์‹(๋‹จ์ผ ํŽ˜์ด์ง€ ์• ํ”Œ๋ฆฌ์ผ€์ด์…˜ ๋˜๋Š” ๋™์ ์œผ๋กœ ์ถ”๊ฐ€๋œ ํ•„๋“œ๊ฐ€ ์žˆ๋Š” ์–‘์‹)์œผ๋กœ ์ž‘์—…ํ•˜๋Š” ๊ฒฝ์šฐ ๋ธŒ๋ผ์šฐ์ €๊ฐ€ ์˜๋„์น˜ ์•Š์€ ๊ณณ์— ์ž˜๋ชป๋œ ๋ฐ์ดํ„ฐ๋ฅผ ์ž๋™ ์ฑ„์šฐ๊ธฐํ•˜๋ฉด ๋ฌธ์ œ๊ฐ€ ๋  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค. ์„ค์ • autocomplete="off"ํ•˜๋ฉด ๋ธŒ๋ผ์šฐ์ €๊ฐ€ ์ด์ „ ์–‘์‹ ํ•ญ๋ชฉ์˜ ๊ฐ’์„ ์ž๋™ ์ œ์•ˆํ•˜์ง€ ์•Š๋„๋ก ํ•  ์ˆ˜ ์žˆ์Šต๋‹ˆ๋‹ค.์–‘์‹ ๋™์ž‘ ์‚ฌ์šฉ์ž ์ •์˜ : ์‚ฌ์šฉ์ž ์ •์˜ ์ž๋™ ์™„์„ฑ ์‹œ์Šคํ…œ์ด๋‚˜ ์–‘์‹ ํ•„๋“œ ๊ฒ€์ฆ๊ณผ ๊ฐ™์€ ์ผ๋ถ€ UX ์‹œ๋‚˜๋ฆฌ์˜ค์˜ ๊ฒฝ..

Front/HTML 2024.10.15

[Error][js] moment.js:1 Deprecation warning: value provided is not in a recognized RFC2822 or ISO format. moment construction falls back to js Date(), which is not reliable across all browsers and versions. Non RFC2822/ISO date formats are discouraged and

Moment.js์˜ ์ด ์‚ฌ์šฉ ์ค‘๋‹จ ๊ฒฝ๊ณ ๋Š” RFC2822 ๋˜๋Š” ISO 8601 ํ˜•์‹์ด ์•„๋‹Œ ๋‚ ์งœ ํ˜•์‹์„ ์ „๋‹ฌํ•˜๊ณ  ์žˆ์Œ์„ ๋‚˜ํƒ€๋ƒ…๋‹ˆ๋‹ค  ํ•ด๊ฒฐ์ฑ…:1. RFC2822 ๋˜๋Š” ISO 8601 ํ˜•์‹์„ ์‚ฌ์šฉํ•˜์„ธ์š”.ISO 8601 ํ˜•์‹ : YYYY-MM-DDTHH:mm:ssZ๋˜๋Š”YYYY-MM-DDmoment("2024-10-14T12:00:00Z");moment("2024-10-14");RFC2822 ํ˜•์‹ :ddd, DD MMM YYYY HH:mm:ss ZZmoment("Mon, 14 Oct 2024 12:00:00 +0000"); 2.๊ธฐ์กด ๋‚ ์งœ ํ˜•์‹์„ ๋ณ€ํ™˜ํ•ฉ๋‹ˆ๋‹ค .moment("10/14/2024", "MM/DD/YYYY");

Error 2024.10.14

FileZilla๋กœ SFTP ์„œ๋ฒ„์— ์—ฐ๊ฒฐ

FileZilla๋ฅผ ์‚ฌ์šฉํ•˜์—ฌ SFTP ์„œ๋ฒ„์— ์—ฐ๊ฒฐํ•˜๋ ค๋ฉด ๋‹ค์Œ ๋‹จ๊ณ„๋ฅผ ๋”ฐ๋ฅด์„ธ์š”:FileZilla ์‹คํ–‰: FileZilla๋ฅผ ์‹คํ–‰ํ•ฉ๋‹ˆ๋‹ค. FileZilla๊ฐ€ ์—†๋‹ค๋ฉด FileZilla ๊ณต์‹ ์‚ฌ์ดํŠธ์—์„œ ๋‹ค์šด๋กœ๋“œํ•˜์—ฌ ์„ค์น˜ํ•˜์„ธ์š”.์ƒˆ ์‚ฌ์ดํŠธ ์„ค์ •:์ƒ๋‹จ ๋ฉ”๋‰ด์—์„œ ํŒŒ์ผ(File) > **์‚ฌ์ดํŠธ ๊ด€๋ฆฌ์ž(Site Manager)**๋ฅผ ํด๋ฆญํ•ฉ๋‹ˆ๋‹ค.์ƒˆ ์‚ฌ์ดํŠธ(New Site) ๋ฒ„ํŠผ์„ ํด๋ฆญํ•˜์—ฌ ์ƒˆ ์—ฐ๊ฒฐ์„ ๋งŒ๋“ญ๋‹ˆ๋‹ค.SFTP ์„œ๋ฒ„ ์ •๋ณด ์ž…๋ ฅ:ํ˜ธ์ŠคํŠธ(Host): 61.80.16.85ํฌํŠธ(Port): 1022ํ”„๋กœํ† ์ฝœ(Protocol): SFTP - SSH File Transfer Protocol์„ ์„ ํƒํ•ฉ๋‹ˆ๋‹ค.๋กœ๊ทธ์˜จ ์œ ํ˜•(Logon Type): **์ผ๋ฐ˜(Normal)**์„ ์„ ํƒํ•ฉ๋‹ˆ๋‹ค.์‚ฌ์šฉ์ž(User): posuser๋น„๋ฐ€๋ฒˆํ˜ธ(Passwor..

IT์ง€์‹ 2024.10.13
728x90
๋ฐ˜์‘ํ˜•