Import Query to Excel with Query Parameters

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

Guest

Hi. I would like to import some data from Access into Excel, but limit the
data by date. When I import the query without the date limitation it works,
but when I adjust the query to limit by date (by putting =[Enter Date] in the
criteria field in my Access Query) I get the error message "Too few
parameters. Expected 1." How do I do this? Thank you!
 
SELECT TBL_TradeBlotter.TBLTransType, TBL_TradeBlotter.TBLAccount,
TBL_TradeBlotter.TBLTradeCode, TBL_TradeBlotter.TBLTradeDate,
TBL_TradeBlotter.TBLSettleDate, TBL_TradeBlotter.TBLActionCode,
TBL_TradeBlotter.TBLQuantity, TBL_TradeBlotter.TBLExecPrice,
TBL_TradeBlotter.TBLSettlementCurrency, TBL_SecurityMaster.TBLCusip,
TBL_SecurityMaster.TBLSecurityName, TBL_TradeBlotter.TBLCommissionCode,
[TBLCommissionRate]*[TBLQuantity] AS CommAmt, TBL_TradeBlotter.TBLExBroker,
TBL_TradeBlotter.TBLBuyCurrency, TBL_TradeBlotter.TBLFXBuyAmount,
TBL_TradeBlotter.TBLSellCurrency, [TBLFXBuyAmount]*[TBLFXRate] AS SellAmt,
TBL_TradeBlotter.TBLFXRate
FROM TBL_SecurityMaster INNER JOIN TBL_TradeBlotter ON
TBL_SecurityMaster.TBLShortName = TBL_TradeBlotter.TBLSecurityID;

Thanks

Klatuu said:
It would be helpful if you post the SQL of the query.
--
Dave Hargis, Microsoft Access MVP


KBHedge said:
Hi. I would like to import some data from Access into Excel, but limit the
data by date. When I import the query without the date limitation it works,
but when I adjust the query to limit by date (by putting =[Enter Date] in the
criteria field in my Access Query) I get the error message "Too few
parameters. Expected 1." How do I do this? Thank you!
 
Back
Top