In the profiler, I saw the following constructions as part of a statement :
(fn locate(@.p1, P_fam_nm))= 1
This look to me as an ODBC function, but I cannot find the function
described in the BOL. The function is problably replaced by a SQL-server
function. (Could be patindex).
Where and how can I find which function is used in SQL-server instead.
Or can SQL-server run this type (ODBC ?) functions ?
ben brugmanI've never heard of that function. I googled it and didn't see any hits
associated with ODBC or MDAC. It doesn't exist on my server. So... I suspect
it's a user defined function.
You can run this statement in all your databases to see where the function
exists.
select * from sysobjects where name like 'fn_locate'
--
Brian Moran
Principal Mentor
Solid Quality Learning
SQL Server MVP
http://www.solidqualitylearning.com
"ben brugman" <ben@.niethier.nl> wrote in message
news:ebZVBx1sDHA.2508@.TK2MSFTNGP12.phx.gbl...
> In the profiler, I saw the following constructions as part of a statement
:
> (fn locate(@.p1, P_fam_nm))= 1
> This look to me as an ODBC function, but I cannot find the function
> described in the BOL. The function is problably replaced by a SQL-server
> function. (Could be patindex).
> Where and how can I find which function is used in SQL-server instead.
> Or can SQL-server run this type (ODBC ?) functions ?
> ben brugman
>|||I see in in the profiler, the coding using it, does work.
The syntax is <(FN locate(string1,string2))
The FN denotes the a function follows.
Behind the FN is a space.
If it is a user defined function the calling program
does define the function before it is called, because
it is not inserted by 'humans'.
And the function does not work from the QA so it
is not present as such.
I'll have a check if the calling program is defining the
function, but this is unlikely to me.
(The workings of the function is very similar (or equal to)
patindex).
ben brugman
"Brian Moran" <brian@.solidqualitylearning.com> wrote in message
news:ucz3LR2sDHA.3492@.TK2MSFTNGP11.phx.gbl...
> I've never heard of that function. I googled it and didn't see any hits
> associated with ODBC or MDAC. It doesn't exist on my server. So... I
suspect
> it's a user defined function.
> You can run this statement in all your databases to see where the function
> exists.
> select * from sysobjects where name like 'fn_locate'
> --
> Brian Moran
> Principal Mentor
> Solid Quality Learning
> SQL Server MVP
> http://www.solidqualitylearning.com
>
> "ben brugman" <ben@.niethier.nl> wrote in message
> news:ebZVBx1sDHA.2508@.TK2MSFTNGP12.phx.gbl...
> > In the profiler, I saw the following constructions as part of a
statement
> :
> >
> > (fn locate(@.p1, P_fam_nm))= 1
> >
> > This look to me as an ODBC function, but I cannot find the function
> > described in the BOL. The function is problably replaced by a SQL-server
> > function. (Could be patindex).
> >
> > Where and how can I find which function is used in SQL-server instead.
> > Or can SQL-server run this type (ODBC ?) functions ?
> >
> > ben brugman
> >
> >
>
No comments:
Post a Comment