PATINDEX (Azure Stream Analytics)
Returns the starting position of the first occurrence of a pattern in a specified expression, or 0 if the pattern is not found, on all valid nvarchar(max) data types.
Syntax
PATINDEX ( '%pattern%' , expression )
Arguments
pattern
A character expression that contains the sequence to be found. Wildcard characters can be used; however, the % character must come before and follow pattern (except when searching for first or last characters). pattern is an expression of the character string data type category. pattern is limited to 8000 characters.
expression
An expression, typically a column that is searched for the specified pattern. Where the expression is of the nvarchar(max) data type.
Return Types
bigint
Examples
SELECT TollId, EntryTime, LicensePlate, PATINDEX ( '%100%',LicensePlate )
FROM Input TIMESTAMP BY EntryTime
Feedback
https://aka.ms/ContentUserFeedback.
Coming soon: Throughout 2024 we will be phasing out GitHub Issues as the feedback mechanism for content and replacing it with a new feedback system. For more information see:Submit and view feedback for