RE: loop through LIST backwards
Posted in 2008
Sounds messy - Can't you set the order by clause on the SELECT query you are using to populate the list for the foreach in the first place? ORDER BY mycolumn DESC; Jarrod Teale -----Original Message----- From: informix-list-bounces@iiug.org [mailto:informix-list-bounces@iiug.org] On Behalf Of Michelle Sent: Tuesday, 14 October 2008 12:31 p.m. To: informix-list@iiug.org Subject: loop through LIST backwards Explanation: I need to write a procedure to change data in a table that branches off into a whole mess of referential constraints. At first I tried just turning off the constraints and changing all the affected tables but due to the tremendous size of the database it was taking way too long. Anyhow, the new method involves changing the tables who's referential constraints stem the farthest out from the parent table first by using temporary table entries. Question: Is there a way to loop through a List backwards? I'm using foreach to run the the list, but need to access it from the bottom to top. _______________________________________________ Informix-list mailing list Informix-list@iiug.org http://www.iiug.org/mailman/listinfo/informix-list DISCLAIMER: This email contains confidential information and may be legally privileged. If you are not the intended recipient or have received this email in error, please notify the sender immediately and destroy this email. You may not use, disclose or copy this email or its attachments in any way. Any opinions expressed in this email are those of the author and are not necessarily those of the Fonterra Co-operative Group. http://www.fonterra.com/