Wednesday, March 7, 2012

Query on 2 tables

Hello all,
If I write this query :
SELECT [Client].[CLI_NAME], [Client].[CLI_PRENOM] FROM Client, Commandes
the return is good.

But If I the query is :

SELECT [Client].[CLI_NOM] & " " & [Commandes].[CMD_DATE_ORDER] As Ordered FROM Client, Commandes
I have an error "Invalid column name.

The CLI_NOM field is on Client Table and CMD_DATE_ORDER is on the other Order table.
How to make a good query with an aliased column without error ?

Thanks for reply.
Regards.
PAB.Try changing this:
& " " &
to this:
& ' ' &|||Also the & should be replaced with +

hth|||Also the
&
should be replaced with
+.

hth|||Hello,
Thanks all. I try that solutions.
PAB.

No comments:

Post a Comment