Query error: Undefined function 'Concatenate' in expression

  • Thread starter Thread starter CW
  • Start date Start date
C

CW

Using Access 2003, we have a table where we hold the various box numbers
holding goods for each order (ref). We want to display the several box
numbers all in one query field. In an earlier post I was directed to a
Concatenate function in Roger's Access Library and I have tried to adapt this
for our application but get the error message "Undefined function
'Concatenate' in expression".

Here is the SQL

SELECT tblStgBoxesForJob.Ref, Concatenate("SELECT StgBoxNbr FROM
tblStgBoxesForJob WHERE Ref =" & [Ref]) AS StgBoxNbr
FROM tblStgBoxesForJob;

Where am I going wrong, please?
Many thanks
CW
 
Did you copy the VBA function (Concatenate) into a VBA module in your database?
Did you save the module with a name other than the name of the concatenate
function (or any other function for that matter)?


John Spencer
Access MVP 2002-2005, 2007-2010
The Hilltop Institute
University of Maryland Baltimore County
 
Er, yes I did re-name it, I removed the "bas" prefix so that it was called
simply "Concatenate" because I naively thought that's what it should be, but
I have now returned bas to its rightful place and it is working fine.
Many thanks John!
CW

John Spencer said:
Did you copy the VBA function (Concatenate) into a VBA module in your database?
Did you save the module with a name other than the name of the concatenate
function (or any other function for that matter)?


John Spencer
Access MVP 2002-2005, 2007-2010
The Hilltop Institute
University of Maryland Baltimore County
Using Access 2003, we have a table where we hold the various box numbers
holding goods for each order (ref). We want to display the several box
numbers all in one query field. In an earlier post I was directed to a
Concatenate function in Roger's Access Library and I have tried to adapt this
for our application but get the error message "Undefined function
'Concatenate' in expression".

Here is the SQL

SELECT tblStgBoxesForJob.Ref, Concatenate("SELECT StgBoxNbr FROM
tblStgBoxesForJob WHERE Ref =" & [Ref]) AS StgBoxNbr
FROM tblStgBoxesForJob;

Where am I going wrong, please?
Many thanks
CW
.
 
Considered finding and using a good naming convention for all Access objects.
It saves us from issues like this ;-)
--
Duane Hookom
Microsoft Access MVP


CW said:
Er, yes I did re-name it, I removed the "bas" prefix so that it was called
simply "Concatenate" because I naively thought that's what it should be, but
I have now returned bas to its rightful place and it is working fine.
Many thanks John!
CW

John Spencer said:
Did you copy the VBA function (Concatenate) into a VBA module in your database?
Did you save the module with a name other than the name of the concatenate
function (or any other function for that matter)?


John Spencer
Access MVP 2002-2005, 2007-2010
The Hilltop Institute
University of Maryland Baltimore County
Using Access 2003, we have a table where we hold the various box numbers
holding goods for each order (ref). We want to display the several box
numbers all in one query field. In an earlier post I was directed to a
Concatenate function in Roger's Access Library and I have tried to adapt this
for our application but get the error message "Undefined function
'Concatenate' in expression".

Here is the SQL

SELECT tblStgBoxesForJob.Ref, Concatenate("SELECT StgBoxNbr FROM
tblStgBoxesForJob WHERE Ref =" & [Ref]) AS StgBoxNbr
FROM tblStgBoxesForJob;

Where am I going wrong, please?
Many thanks
CW
.
 
Back
Top