OleDbException: Undefined function 'xxxxx' in expression

  • Thread starter Thread starter Anastasios
  • Start date Start date
A

Anastasios

Hello all,

I 'm receiving this error:
OleDbException: Undefined function 'xxxxx' in expression

when i try to execute a stored proc. that contain vb functions such as
replace$ or custom function that are declared in access vb modules.

These strored procs are valid and can be executed in the access environment
but fail when executed through a .net client app. Somehow, the app cant
resolve the function calls.

any ideas ?

tks
Anastasios
 
Here is a very simple example:

QUERY1: SELECT replace('ABC','A','*');
when executed in Access returns '*BC'

when executed through a client app i' m getting this :


An unhandled exception of type 'System.Data.OleDb.OleDbException' occurred
in system.data.dll


Unhandled Exception: System.Data.OleDb.OleDbException: Undefined function
'replace' in expression.


at System.Data.OleDb.OleDbCommand.ExecuteCommandTextErrorHandling(Int32 hr)


at
System.Data.OleDb.OleDbCommand.ExecuteCommandTextForSingleResult(tagDBPARAMS
dbParams, Object& executeResult)


at System.Data.OleDb.OleDbCommand.ExecuteCommandText(Object& executeResult)


at System.Data.OleDb.OleDbCommand.ExecuteCommand(CommandBehavior behavior,
Object& executeResult)


at System.Data.OleDb.OleDbCommand.ExecuteReaderInternal(CommandBehavior
behavior, String method)

...............................................

...............................................

...............................................

Anastasios
 
Back
Top