Created
January 26, 2017 20:02
-
-
Save JasonKleban/96a3b4debc802a92edccf86505a64898 to your computer and use it in GitHub Desktop.
Pack tests
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT * FROM [dbo].[UnpackStrings]('|~0123|0|ABC||~0000|DEF|0', '|', '0', '~') | |
SELECT * FROM [dbo].[UnpackStrings]('0|', '|', '0', '~') | |
DECLARE @Test dbo.StringArray | |
PRINT '::' + [dbo].[PackStrings](@Test, '|', '0', '~') + '::' | |
INSERT INTO @Test (Element) | |
VALUES | |
('') | |
,('0123') | |
,(NULL) | |
,('ABC') | |
,('') | |
,('0000') | |
,('DEF') | |
PRINT '::' + [dbo].[PackStrings](@Test, '|', '0', '~') + '::' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment