본문 바로가기
개발/MYSQL

[mysql] 파일전체경로에서 경로와 파일명 분리 기능

by ㅣ푸른하늘ㅣ 2018. 1. 3.
반응형

select 

REPLACE(service_file_path,SUBSTRING_INDEX(service_file_path, '/', -1) , ''),  //파일경로

SUBSTRING_INDEX(service_file_path, '/', -1)  //파일명

From tz_contents order by contents_no desc limit 10000;

반응형

'개발 > MYSQL' 카테고리의 다른 글

DISTINCT 키워드  (0) 2018.07.20
mysql 백업  (0) 2018.01.10