Hi folks! I'm trying to use temp tables to speed up my MySQL 4.1.22-standard database and what seems like a simple operation is causing me all kinds of issues. My code is below....
CREATE TEMPORARY TABLE nonDerivativeTransaction_temp (
accession_number varchar(30),
transactionDateValue date)
) TYPE=HEAP;
INSERT INTO nonDerivativeTransaction_temp
VALUES( SELECT accession_number, transactionDateValue
FROM nonDerivativeTransaction
WHERE transactionDateValue = "2010-06-15");
SELECT *
FROM nonDerivativeTransaction_temp;
The original table (nonDerivativeTransaction) has two fields, accession_number (varchar(30)) and transactionDateValue (date).
Apparently I am getting an issue with the first two statements but I can't seem to nail down what it is. Any help would be appreciated.