A
Andibevan
I have got a paramaterized query that I want to export to excel. The
Transfertoexcel method will work fine for me but I can't get work out how to
pass a variable to the query. MyVariable is my variable (funnily
enough!!) - how would I call this query (called Query_1) from VBA and pass a
parameter?
SELECT [tbl_Sign-off_Approval].[Sign-off Group],
[tbl_Sign-off_groups].[Document Group], [tbl_Sign-off_Approval].[File Name],
[tbl_Sign-off_Approval].Version
FROM [tbl_Sign-off_groups] INNER JOIN [tbl_Sign-off_Approval] ON
[tbl_Sign-off_groups].[Group No] = [tbl_Sign-off_Approval].[Sign-off Group]
WHERE ((([tbl_Sign-off_Approval].[Sign-off Group]) Like MyVariable));
Can you pass a variable to a parameterized query?
TIA
Andi
Transfertoexcel method will work fine for me but I can't get work out how to
pass a variable to the query. MyVariable is my variable (funnily
enough!!) - how would I call this query (called Query_1) from VBA and pass a
parameter?
SELECT [tbl_Sign-off_Approval].[Sign-off Group],
[tbl_Sign-off_groups].[Document Group], [tbl_Sign-off_Approval].[File Name],
[tbl_Sign-off_Approval].Version
FROM [tbl_Sign-off_groups] INNER JOIN [tbl_Sign-off_Approval] ON
[tbl_Sign-off_groups].[Group No] = [tbl_Sign-off_Approval].[Sign-off Group]
WHERE ((([tbl_Sign-off_Approval].[Sign-off Group]) Like MyVariable));
Can you pass a variable to a parameterized query?
TIA
Andi