Cannot run Inline functions

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have an ADP project which I have distributed to 30 clients. The backend
database is SQL Server 2000. The clients are running Office 2003. On some
clients most of the Inline functions (called User defined functions in SQL
Server) do not run. I can open them in design mode but when trying to run
them nothing happens. It seems like this goes to those Inline functions which
contains parameters. I don't thinks it is a SQL permission problem since the
connection properties in ADP project is set to the sa account. Anyone with a
clue?
 
For a reason I don't know, you have to prefix the name of most UDF with its
schema (usually « dbo. ». For example, you have to write dbo.MyUDF()
instead of just MyUDF() to call it (if the schema for MyUDF is dbo, of
course).
 
Unfortunately this solution did not make any difference. I suspect some
missing or old versions of .DLLs or .OCXs. But even though updating with
Service packs etc. it still doesnt work on some Access 2003 clients. I had
the same problem with some workstations running only on Runtime 2002. After
installing Runtime 2003 as well on those workstations the ADP worked on both
Runtime 2002 and 2003. Really strange.
 
JF> Unfortunately this solution did not make any difference. I suspect some
JF> missing or old versions of .DLLs or .OCXs. But even though updating
JF> with Service packs etc. it still doesnt work on some Access 2003
JF> clients. I had the same problem with some workstations running only on
JF> Runtime 2002. After installing Runtime 2003 as well on those
JF> workstations the ADP worked on both Runtime 2002 and 2003. Really
JF> strange. --
JF> Jan Flodin

when you say "nothing happens", what do you mean? can you give an example
that would show how you call those functions?

If you open immediate panel in vba environment, and enter

?currentproject.connection.execute("select dbo.myudf(myparm) from
sometable")(0)

(with right names, obviously), what does it return?

Further, you can always run profiler on sql server to see what happens when
it works and when it does not.

Vadim Rapp
 
If you open immediate panel in vba environment, and enter
?currentproject.connection.execute("select dbo.myudf(myparm) from
sometable")(0)

(with right names, obviously), what does it return?

Probably you would say:

?CurrentProject.Connection.Execute("SELECT dbo.myudf(myparam)")

Right?
 
??>> If you open immediate panel in vba environment, and enter
??>>
??>> ?currentproject.connection.execute("select dbo.myudf(myparm) from
??>> sometable")(0)
??>>
??>> (with right names, obviously), what does it return?

P> Probably you would say:

P> ?CurrentProject.Connection.Execute("SELECT dbo.myudf(myparam)")

P> Right?

Partially. There must (0) in the end, to keep the result. .execute returns
recordset, (0) shows its field.

Vadim Rapp
 
Tried it. For some reason it claims "myudf is not a recognized function
name". Of course I have replaced myudf with the correct name. The thing is
that this message appears also on the clients where the inline functions are
working. You asked me what happens when I try to use a inline function on a
non working client. When I dubbelclick on it in the database window in the
ADP project the screen just blinks for a tenth of a second.
 
Hello Jan,
You wrote on Mon, 25 Jun 2007 22:52:00 -0700:

JF> Tried it. For some reason it claims "myudf is not a recognized function
JF> name".

this is usually returned when you call the udf without schema qualifier,
e.g. SELECT MYUDF() instead of correct SELECT DBO.MYUDF()

If this is not the case, I would run profiler on sql server and see what
comes in.

Vadim Rapp
 
â€â€â€Ž"Jan Flodin said:
I have an ADP project which I have distributed to 30 clients. The backend
database is SQL Server 2000. The clients are running Office 2003. On some
clients most of the Inline functions (called User defined functions in SQL
Server) do not run. I can open them in design mode but when trying to run
them nothing happens. It seems like this goes to those Inline functions
which
contains parameters. I don't thinks it is a SQL permission problem since
the
connection properties in ADP project is set to the sa account. Anyone with
a
clue?
 
Tell me, is anybody ever actually stupid enough to open these things? I
mean, serious, why do you even bother? (Not that you'll ever actually read
this anyway.)



Rob
 
Back
Top