split comma seperated value in database to dropdownlist using vb.net

Last Reply on Mar 29, 2016 04:03 AM By Shashikant

Posted on Mar 29, 2016 03:35 AM

i have pgentry table in my sql server 2005 with the column pg which has comma seperated values.


i have dropdownlist in my webpage, at the time of pageload, the comma seperated values (pg)  in table  (pgentry) should be added to dropdownlist box


Posted on Mar 29, 2016 04:03 AM


Use the following Split function to convert comma separated string to rows.

Split function in SQL Server Example: Function to Split Comma separated (Delimited) string in SQL Server 2005, 2008 and 2012

Then bind the data to DropDownlist

I hope this will help you out.