본문 바로가기

전체 글116

[MSSQL] 쿼리결과 탭 유지 [MSSQL] 쿼리결과 탭 유지 SQL을 쓰다보면 들여쓰기 탭을 썼는데도 불구하고 다음에 열때 엉망으로 열리는 경우가 있음. 프로시져를 예로 들면 이렇게 열려야 하는데 이렇게 들여쓰기가 이상해지고 흐트러지는 경우 해결방법) Solution) 1. 도구 > 옵션 2. 쿼리 결과 > SQL Server > 표 형태로 결과 표시 or 텍스트로 결과 표시 등 필요한 화면 클릭 > 복사 또는 저장 시 CR/LF 보존 클릭 > 확인 2021. 4. 23.
[C#] 같은 문자열 체크 같은 문자열 체크 private bool checkSameStr(string str) { int cnt = 0; for (int i = 0; i = 2) { break; } } if (cnt >= 2) { //3글자 이상 막기 return false; } return true; } 2021. 4. 16.
[C#] 문자열 체크 / 비밀번호 체크 정규식 문자열 체크 (숫자, 영문, 특수문자) (비밀번호 조합 체크) using System.Text.RegularExpressions; private bool checkNumberEnglishSpecialChar(string str) { Regex engRegex = new Regex(@"[a-zA-Z]"); Boolean isMatchEn = engRegex.IsMatch(str); Regex numRegex = new Regex(@"[0-9]"); Boolean isMatchNum = numRegex.IsMatch(str); Regex specialRegex = new Regex(@"[~!@\#$%^&*\()\=+|\\/:;?""']"); Boolean isMatchSpecial = specialRegex.. 2021. 4. 14.
[C#] 비밀번호 공백 체크 비밀번호 공백 체크 (How to check whether input value is included space) using System.Linq; private bool checkSpace(string str) { if (str.Any(x => Char.IsWhiteSpace(x) == true)) { return true; } else { return false; } } 2021. 4. 13.