mysql取部份字串

摘要:mysql取部份字串

SELECT SUBSTR(store_name,1,4)
FROM Geography
WHERE store_name = 'San Diego';

記得要從1開始,不可以從0