table design

  • Thread starter Thread starter angie
  • Start date Start date
A

angie

i have a table with two fields: code and vehicles. no primary key. each code
can correspond to many vehicles: e.g. CIP = citroen (one record), peugeot
(another record). i want to create a query or a report that shows the records
as follows:
CIP = citroen, peugeot.
can i achieve something like that?
 
i have tried this in northwind database and it works fine. in my database i
get the error message "undefined function fconcatfld in expression". i have
created the module and the sql of my query is:

"SELECT CODE, fConcatFld("CODE","VEHICLES","string",
Code:
) AS [BRANDS-TBL]
FROM [BRANDS-TBL]
GROUP BY CODE;"

what could i be doing wrong? maybe it is because there is no primary key in
my table?


Ο χÏήστης "Alex Dybenko" έγγÏαψε:
 
Hi,
no, primary key absence should not be a reason, for some reason function is
not found. Did you save new module? did you compile project?

--
Best regards,
___________
Alex Dybenko (MVP)
http://accessblog.net
http://www.PointLtd.com


angie said:
i have tried this in northwind database and it works fine. in my database
i
get the error message "undefined function fconcatfld in expression". i
have
created the module and the sql of my query is:

"SELECT CODE, fConcatFld("CODE","VEHICLES","string",
Code:
) AS
[BRANDS-TBL]
FROM [BRANDS-TBL]
GROUP BY CODE;"

what could i be doing wrong? maybe it is because there is no primary key
in
my table?


Ο χÏήστης "Alex Dybenko" έγγÏαψε:
[QUOTE]
Hi,
try this approach:
http://www.mvps.org/access/modules/mdl0008.htm

--
Best regards,
___________
Alex Dybenko (MVP)
http://accessblog.net
http://www.PointLtd.com
[/QUOTE][/QUOTE]
 
hi, it seems that there was something wrong with the module name. anyway i
have got the query now but when i run the query i get the error message
"error #13, type mismatch". any idea what the problem might be?

Ο χÏήστης "Alex Dybenko" έγγÏαψε:
Hi,
no, primary key absence should not be a reason, for some reason function is
not found. Did you save new module? did you compile project?

--
Best regards,
___________
Alex Dybenko (MVP)
http://accessblog.net
http://www.PointLtd.com


angie said:
i have tried this in northwind database and it works fine. in my database
i
get the error message "undefined function fconcatfld in expression". i
have
created the module and the sql of my query is:

"SELECT CODE, fConcatFld("CODE","VEHICLES","string",
Code:
) AS
[BRANDS-TBL]
FROM [BRANDS-TBL]
GROUP BY CODE;"

what could i be doing wrong? maybe it is because there is no primary key
in
my table?


Ο χÏήστης "Alex Dybenko" έγγÏαψε:
[QUOTE]
Hi,
try this approach:
http://www.mvps.org/access/modules/mdl0008.htm

--
Best regards,
___________
Alex Dybenko (MVP)
http://accessblog.net
http://www.PointLtd.com


i have a table with two fields: code and vehicles. no primary key. each
code
can correspond to many vehicles: e.g. CIP = citroen (one record),
peugeot
(another record). i want to create a query or a report that shows the
records
as follows:
CIP = citroen, peugeot.
can i achieve something like that?
[/QUOTE][/QUOTE]
[/QUOTE]
 
I think you missed one parameter, tablename:

SELECT CODE, fConcatFld("TableName","CODE","VEHICLES","string",
Code:
)

--
Best regards,
___________
Alex Dybenko (MVP)
http://accessblog.net
http://www.PointLtd.com

[QUOTE="angie"]
hi, it seems that there was something wrong with the module name. anyway i
have got the query now but when i run the query i get the error message
"error #13, type mismatch". any idea what the problem might be?

Ο χÏήστης "Alex Dybenko" έγγÏαψε:
[QUOTE]
Hi,
no, primary key absence should not be a reason, for some reason function
is
not found. Did you save new module? did you compile project?

--
Best regards,
___________
Alex Dybenko (MVP)
http://accessblog.net
http://www.PointLtd.com


[QUOTE="angie"]
i have tried this in northwind database and it works fine. in my
database
i
get the error message "undefined function fconcatfld in expression". i
have
created the module and the sql of my query is:

"SELECT CODE, fConcatFld("CODE","VEHICLES","string",[CODE]) AS
[BRANDS-TBL]
FROM [BRANDS-TBL]
GROUP BY CODE;"

what could i be doing wrong? maybe it is because there is no primary
key
in
my table?


Ο χÏήστης "Alex Dybenko" έγγÏαψε:

Hi,
try this approach:
http://www.mvps.org/access/modules/mdl0008.htm

--
Best regards,
___________
Alex Dybenko (MVP)
http://accessblog.net
http://www.PointLtd.com


i have a table with two fields: code and vehicles. no primary key.
each
code
can correspond to many vehicles: e.g. CIP = citroen (one record),
peugeot
(another record). i want to create a query or a report that shows
the
records
as follows:
CIP = citroen, peugeot.
can i achieve something like that?
[/QUOTE]
[/QUOTE][/QUOTE]
 
yes, i have corrected it, but i still get the same error message. could it be
something with DAO reference missing from my module?

Ο χÏήστης "Alex Dybenko" έγγÏαψε:
I think you missed one parameter, tablename:

SELECT CODE, fConcatFld("TableName","CODE","VEHICLES","string",
Code:
)

--
Best regards,
___________
Alex Dybenko (MVP)
http://accessblog.net
http://www.PointLtd.com

[QUOTE="angie"]
hi, it seems that there was something wrong with the module name. anyway i
have got the query now but when i run the query i get the error message
"error #13, type mismatch". any idea what the problem might be?

Ο χÏήστης "Alex Dybenko" έγγÏαψε:
[QUOTE]
Hi,
no, primary key absence should not be a reason, for some reason function
is
not found. Did you save new module? did you compile project?

--
Best regards,
___________
Alex Dybenko (MVP)
http://accessblog.net
http://www.PointLtd.com


i have tried this in northwind database and it works fine. in my
database
i
get the error message "undefined function fconcatfld in expression". i
have
created the module and the sql of my query is:

"SELECT CODE, fConcatFld("CODE","VEHICLES","string",[CODE]) AS
[BRANDS-TBL]
FROM [BRANDS-TBL]
GROUP BY CODE;"

what could i be doing wrong? maybe it is because there is no primary
key
in
my table?


Ο χÏήστης "Alex Dybenko" έγγÏαψε:

Hi,
try this approach:
http://www.mvps.org/access/modules/mdl0008.htm

--
Best regards,
___________
Alex Dybenko (MVP)
http://accessblog.net
http://www.PointLtd.com


i have a table with two fields: code and vehicles. no primary key.
each
code
can correspond to many vehicles: e.g. CIP = citroen (one record),
peugeot
(another record). i want to create a query or a report that shows
the
records
as follows:
CIP = citroen, peugeot.
can i achieve something like that?
[/QUOTE][/QUOTE]
[/QUOTE]
 
Yes, this could a reason. But can you compile your project? Access will tell
you then in some reference missing

--
Best regards,
___________
Alex Dybenko (MVP)
http://accessblog.net
http://www.PointLtd.com


angie said:
yes, i have corrected it, but i still get the same error message. could it
be
something with DAO reference missing from my module?

Ο χÏήστης "Alex Dybenko" έγγÏαψε:
I think you missed one parameter, tablename:

SELECT CODE, fConcatFld("TableName","CODE","VEHICLES","string",
Code:
)

--
Best regards,
___________
Alex Dybenko (MVP)
http://accessblog.net
http://www.PointLtd.com

[QUOTE="angie"]
hi, it seems that there was something wrong with the module name.
anyway i
have got the query now but when i run the query i get the error message
"error #13, type mismatch". any idea what the problem might be?

Ο χÏήστης "Alex Dybenko" έγγÏαψε:

Hi,
no, primary key absence should not be a reason, for some reason
function
is
not found. Did you save new module? did you compile project?

--
Best regards,
___________
Alex Dybenko (MVP)
http://accessblog.net
http://www.PointLtd.com


i have tried this in northwind database and it works fine. in my
database
i
get the error message "undefined function fconcatfld in expression".
i
have
created the module and the sql of my query is:

"SELECT CODE, fConcatFld("CODE","VEHICLES","string",[CODE]) AS
[BRANDS-TBL]
FROM [BRANDS-TBL]
GROUP BY CODE;"

what could i be doing wrong? maybe it is because there is no primary
key
in
my table?


Ο χÏήστης "Alex Dybenko" έγγÏαψε:

Hi,
try this approach:
http://www.mvps.org/access/modules/mdl0008.htm

--
Best regards,
___________
Alex Dybenko (MVP)
http://accessblog.net
http://www.PointLtd.com


i have a table with two fields: code and vehicles. no primary
key.
each
code
can correspond to many vehicles: e.g. CIP = citroen (one record),
peugeot
(another record). i want to create a query or a report that shows
the
records
as follows:
CIP = citroen, peugeot.
can i achieve something like that?
[/QUOTE]
[/QUOTE][/QUOTE]
 
Back
Top