Forum Replies Created

Viewing 3 posts - 1 through 4 (of 4 total)

  • RE: Passing a comma delimited string to a function for a IN() clause

    ALTER FUNCTION dbo.fnStringToTable(@CommaDelimList varchar(5000), @Delim char(1))

    --*********************************

    --Example;

    --select *

    --from  dbo.fnStringToTable('one, two, three, four', ',')

    --

    --Author: Ed Hellyer

    --Date:  Tuesday July 26th 2006

    --

    --*********************************

    RETURNS @List TABLE (Value varchar(100))

    AS

      BEGIN

     declare @Start int

     set @Start = 1

     while @Start is not null

      ...

  • RE: splitting a sql string

    ALTER FUNCTION dbo.fnStringToTable(@CommaDelimList varchar(5000), @Delim char(1))

    --*********************************

    --Example;

    --select *

    --from  dbo.fnStringToTable('one, two, three, four', ',')

    --

    --Author: Ed Hellyer

    --Date:  Tuesday July 26th 2006

    --

    --*********************************

    RETURNS @List TABLE (Value varchar(100))

    AS

      BEGIN

     declare @Start int

     set @Start = 1

     while @Start is not...

  • RE: Splitting Column Values

    Try this.

     

    ALTER FUNCTION dbo.fnStringToTable(@CommaDelimList varchar(5000), @Delim char(1))

    --*********************************

    --Example;

    --select *

    --from  dbo.fnStringToTable('one, two, three, four', ',')

    --

    --Author: Ed Hellyer

    --Date:  Tuesday July 26th 2006

    --

    --*********************************

    RETURNS @List TABLE (Value varchar(100))

    AS

      BEGIN

     declare @Start int

     set @Start = 1

     while @Start is not...

Viewing 3 posts - 1 through 4 (of 4 total)