crosstab query Access 97

  • Thread starter Thread starter G
  • Start date Start date
G

G

I get an error message when trying to make a cross tab query.

First, I set up a regular query with the criteria set to
the value of a combo box on a form. This works fine.

Then I set up a crosstab query based on the first query.

The error message I get is "The Microsoft Jet database
engine does not recognize
'[Forms]![frmBuildStatementOfLiquidAssets2]![txtClientID]'
as a valid field name or expression. Error 3070."

I attempted to do this just using regular ACCESS query
wizards, as the user has requested me to use as little
coding as possible. Then I tried it with code.

Code for the crosstab is as follows:

TRANSFORM Sum(1.calc_mkt_value) AS [The Value]
SELECT 1.client_id, 1.client, 1.asset_class, 1.asset_name,
Sum(1.calc_mkt_value) AS [Total Of calc_mkt_value] FROM 1
WHERE (((1.client_id) =
[Forms]![frmBuildStatementOfLiquidAssets2]![txtClientID]))
GROUP BY 1.client_id, 1.client, 1.asset_class, 1.asset_name
PIVOT 1.expr;

Thank you in advance for your assistance

G
 
In Cross-Tab Query, you need to declare the Parameter type.

In the design view of the Query, use the Menu command Query / Parameters.
In the dialog, type the Parameter name
([Forms]![frmBuildStatementOfLiquidAssets2]![txtClientID]) in the left
Column and select the appropriate data type in the right Column.
 
Thank you very very much!

G

-----Original Message-----
In Cross-Tab Query, you need to declare the Parameter type.

In the design view of the Query, use the Menu command Query / Parameters.
In the dialog, type the Parameter name
([Forms]![frmBuildStatementOfLiquidAssets2]![txtClientID]) in the left
Column and select the appropriate data type in the right Column.

--
HTH
Van T. Dinh
MVP (Access)




G said:
I get an error message when trying to make a cross tab query.

First, I set up a regular query with the criteria set to
the value of a combo box on a form. This works fine.

Then I set up a crosstab query based on the first query.

The error message I get is "The Microsoft Jet database
engine does not recognize
'[Forms]![frmBuildStatementOfLiquidAssets2]![txtClientID]'
as a valid field name or expression. Error 3070."

I attempted to do this just using regular ACCESS query
wizards, as the user has requested me to use as little
coding as possible. Then I tried it with code.

Code for the crosstab is as follows:

TRANSFORM Sum(1.calc_mkt_value) AS [The Value]
SELECT 1.client_id, 1.client, 1.asset_class, 1.asset_name,
Sum(1.calc_mkt_value) AS [Total Of calc_mkt_value] FROM 1
WHERE (((1.client_id) =
[Forms]![frmBuildStatementOfLiquidAssets2]![txtClientID]))
GROUP BY 1.client_id, 1.client, 1.asset_class, 1.asset_name
PIVOT 1.expr;

Thank you in advance for your assistance

G


.
 
Back
Top