Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
Author |
Topic |
cnbhold
Starting Member
43 Posts |
Posted - 2012-11-07 : 20:53:18
|
I need a way to only select the characters before the comma which are not the same length.ExampleRussell,123456Cranford,6575647Wells,9878676Desired ResultsRussellCranfordWellsAngel |
|
khtan
In (Som, Ni, Yak)
17689 Posts |
Posted - 2012-11-07 : 22:40:17
|
[code]left(<column name>, charindex(',', <column name> + ',') - 1)[/code] KH[spoiler]Time is always against us[/spoiler] |
|
|
cnbhold
Starting Member
43 Posts |
Posted - 2012-11-07 : 23:31:38
|
khtan,Thanks!!! Your code worked great!!Angel |
|
|
|
|
|