Last updated 1 month ago
SQL Server
Azure Synapse Analytics
Returns a number of occurrences of blank spaces ().
Custom function used to emulate the behavior
Input:
Output:
No issues were found.
No related EWIs.
SPACE ( integer_expression )
SPACE(<n>)
function SPACE( occurrences ){ return ' '.repeat( occurrences ); }
SELECT CONCAT('SOME', SPACE(5), 'TEXT') AS RESULT;
RESULT | -------------+ SOME TEXT|
CREATE OR REPLACE FUNCTION SPACE(occurrences float) RETURNS string LANGUAGE JAVASCRIPT AS $$ function SPACE( occurrences ){ return ' '.repeat( occurrences ); } return SPACE( OCCURRENCES ); $$; SELECT CONCAT('SOME', SPACE(5), 'TEXT') RESULT;