[js] indexOf() ๋ฌธ์์ด ๋ฌธ์์ด์ ํด๋น ๋ฌธ์๊ฐ ํฌํจ๋์ด์๋์ง ํ์ธํ๋ jsํจ์ function containsCharacter(str, char) { return str.indexOf(char) !== -1; } ํด๋น๋ฌธ์๊ฐ ํฌํจ๋์ด์์ง ์์ผ๋ฉด -1 ๋ฐํํ๋ ๊ฒ์ ์ด์ฉ Front/JS & jQuery 2024.04.20
[jQuery][datatables] excel download ์ ํผ์ผํธ data๊ฐ ์์๋ก ์ถ๋ ฅ๋๋ ํ์ $('#example').DataTable( { dom: 'Bfrtip', buttons: [ { extend: 'excelHtml5', title: 'YourTitle', exportOptions: { format: { body: function (data, row, column, node) { if (typeof(data) === 'string') { if(data.indexOf('%') != -1) { if(data.split('%')[1].length Front/JS & jQuery 2024.04.19
[DB][SQL] ํ์ฌ ์ปฌ๋ผ์ ๊ฐ์ ์ฐ์ฐํ์ฌ Update ํ๊ธฐ ํ์ฌ ๋ฐ์ดํฐ * 2๋ก ์ปฌ๋ผ ๋ฐ์ดํฐ updqte ํ๋ ์ฟผ๋ฆฌ UPDATE table_name SET column_name = column_name * 2; DB 2024.04.18
[JAVA ]String์ LocalDate๋ก ๋ณํ https://codechacha.com/ko/java-examples-how-to-convert-string-to-localdate/ Java - String์ ํ์ฑํ์ฌ LocalDate๋ก ๋ณํํ๋ ๋ฐฉ๋ฒ LocalDate์ DateTimeFormatter ๋ผ์ด๋ธ๋ฌ๋ฆฌ๋ฅผ ์ด์ฉํ๋ฉด ๋ฌธ์๋ก ๋ ๋ ์ง๋ฅผ Date ๊ฐ์ฒด๋ก ๋ณํํ ์ ์์ต๋๋ค. ์คํธ๋ง์ Date๊ฐ์ฒด๋ก ๋ณํํ๋ฉด ๋ ์ง ๊ณ์ฐ ๋ฑ ๋ฐ์ดํฐ๋ฅผ ์ฒ๋ฆฌํ๋๋ฐ ํธ๋ฆฌํฉ๋๋ค. ์์ ๋ฅผ ํตํด ์ด codechacha.com DateTimeFormatter ์ผ๋ก format์ ์์ ํด์ฃผ๊ณ ํ๋ ค๊ณ ํ๋ ์๋ฌ๊ฐ ๋ฌ์๋ค. JAVA 2024.04.17
[DB][Dbeaver] ๊ณต๋ฐฑ์๋ ์ฟผ๋ฆฌ ์คํํ๋ ๋ฐฉ๋ฒ https://hihighlinux.tistory.com/128 DBeaver ๊ณต๋ฐฑ์ด์๋ ์ฟผ๋ฆฌ ์คํ์ค๋ฅ! ๋๋น๋ฒ ํด์ ์ต์ํด์ง๊ณ ์๋ค. ๊ทผ๋ฐ ์ฟผ๋ฆฌ ์คํํ๋ค ์ํฐ์ฒ๋ฆฌ๋ ๋ถ๋ถ(๊ณต๋ฐฑ) ์์ ์๊พธ ์๋ฌ๊ฐ ๋ฌ๋ค. ์ด๋ ๊ฒ! ํ๊ฒฝ์ค์ ์์ ์ค์ ํด์ฃผ๋๊ฒ ์์ ๊ฒ ๊ฐ์์ ์ฐพ์๋ดค๋ค! SQL์คํ ๋ถ๋ถ์ ์ฐพ์๋ณด๋ ์๋ค. hihighlinux.tistory.com DB 2024.04.16
[Error][MyBatis] Error evaluating expression 'param.crchTp'. Return value () was not iterable. https://selfdevelope.tistory.com/694#google_vignette Error evaluating expression. Return value was not iterable. jsp ์์ var cList = new Array(); cList.push("5"); cList.push("6"); ํด์ ๊ฐ์ ๋๊ธฐ๊ณ mybatis์์ ์ธ๋ ค๊ณ ํ๋๋ฐ AND AA in #{C_MM,jdbcType=VARCHAR} org.mybatis.spring.MyBatisSystemException: nested exception is org.apache.ibatis.builder.Buil selfdevelope.tistory.com Error 2024.04.14
[HTML][bootstrap] data-toggle ="dropdown" https://bootstrap21.org/ko/docs/4.1/components/dropdowns/# ๋๋กญ๋ค์ด · ๋ถํธ์คํธ๋ฉ ํ๊ตญ์ด๋ก Source ๋๋กญ๋ค์ด ๋ถํธ์คํธ๋ฉ ๋๋กญ๋ค์ด ํ๋ฌ๊ทธ์ธ์ ์ฌ์ฉํ์ฌ ๋งํฌ ๋ชฉ๋ก ๋ฑ์ ํ์ํ๊ธฐ ์ํ ์ํฉ๋ณ ์ค๋ฒ๋ ์ด๋ฅผ ํ ๊ธํฉ๋๋ค. ๋๋กญ๋ค์ด์ ๋งํฌ ๋ชฉ๋ก ๋ฑ์ ํ์ํ๊ธฐ ์ํ ํ ๊ธ ๊ฐ๋ฅํ ์ํฉ๋ณ ์ค๋ฒ๋ bootstrap21.org Front/HTML 2024.04.13
[DB] auto_increment ์ปฌ๋ผ์ primary ํค ๋ง๊ณ unique ํค๋ก ์ค์ ํ๋ฉด? ๋ ์ฆ๊ฐ ์ด์ ๊ธฐ๋ณธ ํค ๋์ ๊ณ ์ ํค๋ฅผ ์ฌ์ฉํ๋ ค๋ ๊ฒฝ์ฐ์๋ ์ด๋ฅผ ๋ฌ์ฑํ ์ ์์ต๋๋ค. ๊ทธ๋ฌ๋ ๊ณ ์ ํค๋ NULL ๊ฐ์ ํ์ฉํ์ง ์๋ ๋ฑ ๊ธฐ๋ณธ ํค์ ๋์ผํ ์ ์ฝ ์กฐ๊ฑด์ ๋ฐ๋์ ์ ์ฉํ์ง๋ ์์ต๋๋ค. ๋ค์์ ๊ณ ์ ํค ์ ์ฝ ์กฐ๊ฑด์ด ์๋ ์๋ ์ฆ๊ฐ ์ด์ด ์๋ ํ ์ด๋ธ์ ์ ์ํ๋ ๋ฐฉ๋ฒ์ ๋ํ ์์ ๋๋ค. CREATE TABLE your_table_name ( id INT AUTO_INCREMENT UNIQUE, column1 DATATYPE, column2 DATATYPE, ... ); ์ด ์์์ ์ id์๋ ์ฆ๊ฐ ์ด์ด๋ฉฐ ๊ณ ์ ํ ๊ฒ์ผ๋ก ํ์๋์ด ์์ต๋๋ค. ์ฆ, ์ด์ ๊ฐ ๊ฐ์ id๊ณ ์ ํด์ผ ํ์ง๋ง ๋ฐ๋์ ํ ์ด๋ธ์ ๊ธฐ๋ณธ ํค์ผ ํ์๋ ์์ต๋๋ค. ๊ทธ๋ฌ๋ ๊ธฐ๋ณธ ํค ๋์ ๊ณ ์ ํค๋ฅผ ์ฌ์ฉํ๋ฉด ํน์ ์ฌ์ฉ ์ฌ๋ก ๋ฐ ๋ฐ์ดํฐ๋ฒ ์ด์ค ์๊ตฌ ์ฌ.. DB 2024.04.12
[Error][DB] SQL Error [1075] [42000]: Incorrect table definition; there can be only one auto column and it must be defined as a key ํ์๋๋ ์ค๋ฅ ๋ฉ์์ง๋ SQL ์ฟผ๋ฆฌ์ ํ ์ด๋ธ ์ ์์ ๋ฌธ์ ๊ฐ ์์์ ๋ํ๋ ๋๋ค. ์ค๋ฅ๋ ์ฌ๋ฌ ๊ฐ์ ์๋ ์ฆ๊ฐ ์ด์ ์ ์ํ๋ ค๊ณ ํ๋ฉฐ ์ด๋ฌํ ์ด์ ํ๋๋ง ํ์ฉ๋๋ฉฐ ํค(์ผ๋ฐ์ ์ผ๋ก ๊ธฐ๋ณธ ํค)๋ก๋ ์ ์๋์ด์ผ ํจ์ ๋ํ๋ ๋๋ค. ์ด ๋ฌธ์ ๋ฅผ ํด๊ฒฐํ๋ ค๋ฉด ๋ค์์ ํ์ธํ์ญ์์ค. ํ ์ด๋ธ ์ ์์ ์๋ ์ฆ๊ฐ ์ด์ด ํ๋๋ง ์๋์ง ํ์ธํ์ญ์์ค. ์ด ์๋ ์ฆ๊ฐ ์ด์ ํค(์ผ๋ฐ์ ์ผ๋ก ๊ธฐ๋ณธ ํค)๋ก ์ ์ํฉ๋๋ค. ๋ค์์ ์๋ ์ฆ๊ฐ ๊ธฐ๋ณธ ํค ์ด์ด ์๋ ํ ์ด๋ธ์ ์ ์ํ๋ ๋ฐฉ๋ฒ์ ๋ํ ๊ธฐ๋ณธ ์์ ๋๋ค. CREATE TABLE your_table_name ( id INT AUTO_INCREMENT PRIMARY KEY, column1 DATATYPE, column2 DATATYPE, ... ); ์ด ์์์๋ id์๋ ์ฆ๊ฐ ๊ธฐ๋ณธ ํค ์ด์ ๋๋ค. ํน์ ํ ์ด๋ธ.. Error 2024.04.11