PC Review


Reply
Thread Tools Rate Thread

Dev Ashish - fConcatFld function assistance

 
 
Katie Fitzpatrick
Guest
Posts: n/a
 
      21st Jul 2010
Hello all -

I *know* this has been covered many places, but my hours of searching
has yielded me no resolution to what I imagine is a pretty simple
problem.

I have one table: Sample
There two columns I'm interested in are: UserId and Role
I am (attempting) to use Dev Ashish's fConcatFld function to produce a
simple select statement that would produce the following:

Before:

UserID Role
Sam ABC System
Sam XYZ System
Joe ABC System
Joe ABC System Admin
Sam ABC Admin

After:

UserID Role
Sam ABC System, XYZ System, ABC Admin
Joe ABC System, ABC System Admin


I followed the instructions to enter a code window, insert a module,
pasted the code, ran compile under the debug menu.

Then I entered the following into a query:

SELECT Userid, fConcatFld("Sample","UserID","Role","string",[Userid])
AS Roles
FROM Sample
GROUP BY [Userid];

The error I receive is as follows:

"Undefined Function 'fConcatFld" in expression"

The function is declared as public - what am I missing?

Thank you so much for your assistance with this question.
 
Reply With Quote
 
 
 
 
Katie Fitzpatrick
Guest
Posts: n/a
 
      21st Jul 2010
On Jul 21, 12:32*pm, Katie Fitzpatrick <katepass...@gmail.com> wrote:
> Hello all -
>
> I *know* this has been covered many places, but my hours of searching
> has yielded me no resolution to what I imagine is a pretty simple
> problem.
>
> I have one table: Sample
> There two columns I'm interested in are: UserId and Role
> I am (attempting) to use Dev Ashish's fConcatFld function to produce a
> simple select statement that would produce the following:
>
> Before:
>
> UserID * * * * * * Role
> Sam * * * * * * * *ABC System
> Sam * * * * * * * *XYZ System
> Joe * * * * * * * * *ABC System
> Joe * * * * * * * * *ABC System Admin
> Sam * * * * * * * *ABC Admin
>
> After:
>
> UserID * * * * * * Role
> Sam * * * * * * * *ABC System, XYZ System, ABC Admin
> Joe * * * * * * * * ABC System, ABC System Admin
>
> I followed the instructions to enter a code window, insert a module,
> pasted the code, ran compile under the debug menu.
>
> Then I entered the following into a query:
>
> SELECT Userid, fConcatFld("Sample","UserID","Role","string",[Userid])
> AS Roles
> FROM Sample
> GROUP BY [Userid];
>
> The error I receive is as follows:
>
> "Undefined Function 'fConcatFld" in expression"
>
> The function is declared as public - what am I missing?
>
> Thank you so much for your assistance with this question.


I posted in the incorrect location. I will repost to
microsoft.public.access.queries
 
Reply With Quote
 
Douglas J. Steele
Guest
Posts: n/a
 
      21st Jul 2010
Where did you copy the code for fConcatFld?

It must be in a stand-alone module (as opposed to a Class module or a module
associated with a report or form)

--
Doug Steele, Microsoft Access MVP
http://www.AccessMVP.com/DJSteele
Co-author: Access 2010 Solutions, published by Wiley
(no e-mails, please!)

"Katie Fitzpatrick" <(E-Mail Removed)> wrote in message
news:48993a86-2394-4148-bd83-(E-Mail Removed)...
> Hello all -
>
> I *know* this has been covered many places, but my hours of searching
> has yielded me no resolution to what I imagine is a pretty simple
> problem.
>
> I have one table: Sample
> There two columns I'm interested in are: UserId and Role
> I am (attempting) to use Dev Ashish's fConcatFld function to produce a
> simple select statement that would produce the following:
>
> Before:
>
> UserID Role
> Sam ABC System
> Sam XYZ System
> Joe ABC System
> Joe ABC System Admin
> Sam ABC Admin
>
> After:
>
> UserID Role
> Sam ABC System, XYZ System, ABC Admin
> Joe ABC System, ABC System Admin
>
>
> I followed the instructions to enter a code window, insert a module,
> pasted the code, ran compile under the debug menu.
>
> Then I entered the following into a query:
>
> SELECT Userid, fConcatFld("Sample","UserID","Role","string",[Userid])
> AS Roles
> FROM Sample
> GROUP BY [Userid];
>
> The error I receive is as follows:
>
> "Undefined Function 'fConcatFld" in expression"
>
> The function is declared as public - what am I missing?
>
> Thank you so much for your assistance with this question.



 
Reply With Quote
 
David W. Fenton
Guest
Posts: n/a
 
      21st Jul 2010
Katie Fitzpatrick <(E-Mail Removed)> wrote in
news:e1c3d799-48c8-4629-86ec-(E-Mail Removed)
m:

> I posted in the incorrect location. I will repost to
> microsoft.public.access.queries


I'd suggest you just post in microsoft.public.access or
comp.databases.ms-access, since the traffic is so much lower now
that MS has stopped participating in them.

--
David W. Fenton http://www.dfenton.com/
usenet at dfenton dot com http://www.dfenton.com/DFA/
 
Reply With Quote
 
Katie Fitzpatrick
Guest
Posts: n/a
 
      21st Jul 2010
On Jul 21, 1:34*pm, "Douglas J. Steele"
<NOSPAM_djsteele@NOSPAM_gmail.com> wrote:
> Where did you copy the code for fConcatFld?
>
> It must be in a stand-alone module (as opposed to a Class module or a module
> associated with a report or form)
>
> --
> Doug Steele, Microsoft Access MVPhttp://www.AccessMVP.com/DJSteele
> Co-author: Access 2010 Solutions, published by Wiley
> (no e-mails, please!)
>
> "Katie Fitzpatrick" <katepass...@gmail.com> wrote in message
>
> news:48993a86-2394-4148-bd83-(E-Mail Removed)...
>
>
>
> > Hello all -

>
> > I *know* this has been covered many places, but my hours of searching
> > has yielded me no resolution to what I imagine is a pretty simple
> > problem.

>
> > I have one table: Sample
> > There two columns I'm interested in are: UserId and Role
> > I am (attempting) to use Dev Ashish's fConcatFld function to produce a
> > simple select statement that would produce the following:

>
> > Before:

>
> > UserID * * * * * * Role
> > Sam * * * * * * * *ABC System
> > Sam * * * * * * * *XYZ System
> > Joe * * * * * * * * *ABC System
> > Joe * * * * * * * * *ABC System Admin
> > Sam * * * * * * * *ABC Admin

>
> > After:

>
> > UserID * * * * * * Role
> > Sam * * * * * * * *ABC System, XYZ System, ABC Admin
> > Joe * * * * * * * * ABC System, ABC System Admin

>
> > I followed the instructions to enter a code window, insert a module,
> > pasted the code, ran compile under the debug menu.

>
> > Then I entered the following into a query:

>
> > SELECT Userid, fConcatFld("Sample","UserID","Role","string",[Userid])
> > AS Roles
> > FROM Sample
> > GROUP BY [Userid];

>
> > The error I receive is as follows:

>
> > "Undefined Function 'fConcatFld" in expression"

>
> > The function is declared as public - what am I missing?

>
> > Thank you so much for your assistance with this question.


Hi David -

I found the code here: http://www.mvps.org/access/modules/mdl0008.htm

However, I'm not sure that I've created it as a stand-alone module.
How could I check that?
 
Reply With Quote
 
Katie Fitzpatrick
Guest
Posts: n/a
 
      21st Jul 2010
On Jul 21, 1:48*pm, "David W. Fenton" <XXXuse...@dfenton.com.invalid>
wrote:
> Katie Fitzpatrick <katepass...@gmail.com> wrote innews:e1c3d799-48c8-4629-86ec-(E-Mail Removed)
> m:
>
> > I posted in the incorrect location. I will repost to
> > microsoft.public.access.queries

>
> I'd suggest you just post in microsoft.public.access or
> comp.databases.ms-access, since the traffic is so much lower now
> that MS has stopped participating in them.
>
> --
> David W. Fenton * * * * * * * * *http://www.dfenton.com/
> usenet at dfenton dot com * *http://www.dfenton.com/DFA/


Thanks David - I didn't realize they had stopped participating. I will
make a note for the future.
 
Reply With Quote
 
David W. Fenton
Guest
Posts: n/a
 
      22nd Jul 2010
Katie Fitzpatrick <(E-Mail Removed)> wrote in
news:60225be6-4cd7-4723-a17e-(E-Mail Removed)
m:

> I found the code here:
> http://www.mvps.org/access/modules/mdl0008.htm
>
> However, I'm not sure that I've created it as a stand-alone
> module. How could I check that?


It doesn't have to be in a standalone module by itself, just in *a*
standalone module.

If you went to the modules tab and hit NEW and pasted it there,
you've already got that.

--
David W. Fenton http://www.dfenton.com/
usenet at dfenton dot com http://www.dfenton.com/DFA/
 
Reply With Quote
 
 
 
Reply

Thread Tools
Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
function assistance JohnE Microsoft Access Form Coding 5 4th Nov 2009 10:11 PM
RE: IF Function assistance Ron@Buy Microsoft Excel Discussion 0 11th May 2009 12:05 PM
Help with Dev Ashish's fConcatChild function Ray S. Microsoft Access 4 14th Feb 2008 03:53 PM
Assistance for the IF Function =?Utf-8?B?S2VudHVja3kgSG90IEJyb3du?= Microsoft Excel Misc 3 4th Sep 2007 02:53 AM
If Function Assistance =?Utf-8?B?Q2hyaXMgQi4=?= Microsoft Excel Worksheet Functions 3 29th Sep 2006 04:30 PM


Features
 

Advertising
 

Newsgroups
 


All times are GMT +1. The time now is 04:02 AM.