C# LastIndexOf ve Substring İşlemini SQL’de Yapmak

Hunili Yazılımcı
Aug 7, 2016 · 1 min read

C#’da kullandığımız LastIndexOf ve Substring fonksiyonunu SQL üzerinde kayıtlarınızda topluca işlem yapmak istediğiniz gibi durumlarda kullanmanız gerektiğinde benim bulduğum çözüm aşağıdaki gibi oldu.

C #

dd_string.Substring(dd_string.LastIndexOf("_") + 1);


RIGHT(string, CHARINDEX('_', REVERSE('_' + string)) -1)



Welcome to a place where words matter. On Medium, smart voices and original ideas take center stage - with no ads in sight. Watch

Follow all the topics you care about, and we’ll deliver the best stories for you to your homepage and inbox. Explore

Get unlimited access to the best stories on Medium — and support writers while you’re at it. Just $5/month. Upgrade

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store