You could try something like this:
NOTE: you may or may not need the:Code:SET @LAUNCH_DATE := '2012-01-01'; CREATE TABLE customers2012 ENGINE=MyISAM AS SELECT * FROM address_book WHERE customers_id IN (select customers_info_id FROM customers_info WHERE customers_info_date_of_last_logon < @LAUNCH_DATE) ORDER BY `address_book`.`customers_id` DESC;
ENGINE=MyISAM
depending on your current tables ...


Reply With Quote
