Having trouble with ADO to run a access query From Excel

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

Guest

Hello This may not be were I in need to post this ? If its not can someone
tell me where to post. The Where is my problem. The SQL below is in access
and I have a form to pick the between Receiving.RECEIVE_DATE. I would Like
to use my form in Excel to pick the between Dates Can anyone help

SELECT DISTINCTROW Receiving.RECEIVE_DATE, Receiving.INVOICE_NUMBER,
Receiving.RPT_GROUP1, Receiving.DEPT_GRP, Sum(Receiving.COST) AS [Sum Of
COST], Receiving.VENDOR_ID, Sys_Pram.STORE_NAME
FROM Receiving, Sys_Pram
WHERE (((Receiving.RECEIVE_DATE) Between
[Forms]![frmDatePicker]![txtStartDate] And
[Forms]![frmDatePicker]![txtEndDate]+1)
GROUP BY Receiving.RECEIVE_DATE, Receiving.INVOICE_NUMBER,
Receiving.RPT_GROUP1, Receiving.DEPT_GRP, Receiving.VENDOR_ID,
Sys_Pram.STORE_NAME;
 
Hello This may not be were I in need to post this ? If its not can someone
tell me where to post. The Where is my problem. The SQL below is in access
and I have a form to pick the between Receiving.RECEIVE_DATE. I would Like
to use my form in Excel to pick the between Dates Can anyone help

SELECT DISTINCTROW Receiving.RECEIVE_DATE, Receiving.INVOICE_NUMBER,
Receiving.RPT_GROUP1, Receiving.DEPT_GRP, Sum(Receiving.COST) AS [Sum Of
COST], Receiving.VENDOR_ID, Sys_Pram.STORE_NAME
FROM Receiving, Sys_Pram
WHERE (((Receiving.RECEIVE_DATE) Between
[Forms]![frmDatePicker]![txtStartDate] And
[Forms]![frmDatePicker]![txtEndDate]+1)
GROUP BY Receiving.RECEIVE_DATE, Receiving.INVOICE_NUMBER,
Receiving.RPT_GROUP1, Receiving.DEPT_GRP, Receiving.VENDOR_ID,
Sys_Pram.STORE_NAME;

Do you mean, "I would like to use my Access form from within Excel to
pick the between Dates," or do you mean, "I have an Excel form to pick
the between Dates and I want to pass the parameter values to my SQL
procedure"? TIA.

Jamie.

--
 
I have got what i need for now Ty. I ment a form within Excel. Is it possible
to use the Access Form?

Jamie Collins said:
Hello This may not be were I in need to post this ? If its not can someone
tell me where to post. The Where is my problem. The SQL below is in access
and I have a form to pick the between Receiving.RECEIVE_DATE. I would Like
to use my form in Excel to pick the between Dates Can anyone help

SELECT DISTINCTROW Receiving.RECEIVE_DATE, Receiving.INVOICE_NUMBER,
Receiving.RPT_GROUP1, Receiving.DEPT_GRP, Sum(Receiving.COST) AS [Sum Of
COST], Receiving.VENDOR_ID, Sys_Pram.STORE_NAME
FROM Receiving, Sys_Pram
WHERE (((Receiving.RECEIVE_DATE) Between
[Forms]![frmDatePicker]![txtStartDate] And
[Forms]![frmDatePicker]![txtEndDate]+1)
GROUP BY Receiving.RECEIVE_DATE, Receiving.INVOICE_NUMBER,
Receiving.RPT_GROUP1, Receiving.DEPT_GRP, Receiving.VENDOR_ID,
Sys_Pram.STORE_NAME;

Do you mean, "I would like to use my Access form from within Excel to
pick the between Dates," or do you mean, "I have an Excel form to pick
the between Dates and I want to pass the parameter values to my SQL
procedure"? TIA.

Jamie.
 
Back
Top