x

what is the use of padindex function

what is the use of padindex function , when and where can be used ?

more ▼

asked Nov 21, 2011 at 11:08 PM in Default

avatar image

jhunu
110 29 30 35

(comments are locked)
10|1200 characters needed characters left

2 answers: sort voted first

Returns the starting position of the first occurrence of a pattern in a specified expression, or zeros if the pattern is not found, on all valid text and character data types. syntax : PATINDEX ( '%pattern%' , expression )

more ▼

answered Nov 21, 2011 at 11:18 PM

avatar image

viikiseth
51 1

(comments are locked)
10|1200 characters needed characters left

I'm confused.

Do you mean the PATINDEX function, which, as @viikiseth has indicated, is for string pattern matching - see also http://msdn.microsoft.com/en-us/library/ms188395.aspx

Or did you mean PAD INDEX, which you can use to tune index performance - see http://msdn.microsoft.com/en-us/library/ms186872.aspx

I'm guessing, by the way you described it as a function, that you meant the former...

more ▼

answered Nov 25, 2011 at 12:16 PM

avatar image

ThomasRushton ♦♦
39.8k 20 49 52

(comments are locked)
10|1200 characters needed characters left
Your answer
toggle preview:

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

SQL Server Central

Need long-form SQL discussion? SQLserverCentral.com is the place.

Topics:

x6

asked: Nov 21, 2011 at 11:08 PM

Seen: 630 times

Last Updated: Nov 25, 2011 at 12:12 PM

Copyright 2016 Redgate Software. Privacy Policy