R
Rob Wills
Hi,
I've just been tinkering with a little project of mine, looking at using
"views" to streamline a new process and came across the following anomaly.
Basically I created a view using the following:
currentproject.Connection.Execute "Create VIEW vw_Canceled as Select * From
tblCashFlowsHistorical WHERE TradeStatus = 'Canceled'"
(No rocket science here)
And after checking the results I confirmed that this worked perfectly.
Then I decided to run an action on the view in the immediate window...
currentproject.Connection.Execute "INSERT INTO tblCashFlowsHistorical_OUT
SELECT * FROM vw_Principal"
This didn’t work....
However.... This did?!?!?
Currentdb.Execute "INSERT INTO tblCashFlowsHistorical_OUT SELECT * FROM
vw_Principal"
I copied and pasted the SQL – so there’s no typos, no error messages, it
just didn’t move the records to the “Out†table as expected.
BTW I'm using Access 2007 (accdb)
Any advice would be most welcome...
Thanks
Rob
I've just been tinkering with a little project of mine, looking at using
"views" to streamline a new process and came across the following anomaly.
Basically I created a view using the following:
currentproject.Connection.Execute "Create VIEW vw_Canceled as Select * From
tblCashFlowsHistorical WHERE TradeStatus = 'Canceled'"
(No rocket science here)
And after checking the results I confirmed that this worked perfectly.
Then I decided to run an action on the view in the immediate window...
currentproject.Connection.Execute "INSERT INTO tblCashFlowsHistorical_OUT
SELECT * FROM vw_Principal"
This didn’t work....
However.... This did?!?!?
Currentdb.Execute "INSERT INTO tblCashFlowsHistorical_OUT SELECT * FROM
vw_Principal"
I copied and pasted the SQL – so there’s no typos, no error messages, it
just didn’t move the records to the “Out†table as expected.
BTW I'm using Access 2007 (accdb)
Any advice would be most welcome...
Thanks
Rob