Array Sorting


sorry asking again. have fallen ill weekend , need done tuesday. 3d array believe , not sorting. sorting numbers ascending order. code attached below need with.


any thoughts, sorry cfml beginner , advanced programmer developed has moved on company. please advise.
attach code

<br>
<table width="600" border="0" cellspacing="0" cellpadding="0">
<tr>
<td valign="top">
<table width="600" border="0" cellspacing="0" cellpadding="0">
<tr>
<td>
<p align="center" style="font-size: 14px; font-weight: bold;">
multiple drypress green machine &quot;l&quot; x sect. blank pricing - dimensions , details
</p>
</td>
</tr>
</table>

<div align="center">
<table width="600" border="0" cellspacing="2" cellpadding="2">
<tr>
<td><div class="small"><b>material</b></div></td>
<td><div class="small" align="center"><b>od</b></div></td>
<td><div class="small" align="center"><b>id</b></div></td>
<td><div class="small" align="center"><b>thk</b></div></td>
<td><div class="small"><b>500 pieces $ each</b></div></td>
<td><div class="small"><b>1000 pieces $ each</b></div></td>
<td><div class="small"><b>2500 pieces $ each</b></div></td>
<td><div class="small"><b>5000 pieces $ each</b></div></td>
<td><div class="small"><b>10000 pieces $ each</b></div></td>
<td><div class="small"><b>25000 pieces $ each</b></div></td>
<td><div class="small"><b>non-recurring charge $</b></div></td>
</tr>
<cfloop collection="#variables.queue_copy#" item="key">

<cfset attributes.od = variables.queue_copy[key]["od"]>
<cfset attributes.id = variables.queue_copy[key]["id"]>
<cfset attributes.thk = variables.queue_copy[key]["thk"]>
<cfset product_type = listgetat(attributes.product, 1, "_")>

<cfif attributes.product eq "isopress_tubes">
<cfset product_type = "isopress_tubes">
</cfif>

<cfparam name="temp_od" default="#attributes.od#">

<cftry>

<cfif attributes.measure eq "metric">
<cfset temp_od = attributes.od / 25.4>
<cfif isdefined("attributes.thk")><cfset temp_thk = attributes.thk / 25.4></cfif>
<cfelse>
<cfif isdefined("attributes.thk")><cfset temp_thk = attributes.thk></cfif>
</cfif>

<cfcatch>
</cfcatch>

</cftry>

<cfquery name="qtolerance" datasource="#request.dsn#" dbtype="odbc">
select *
from #product_type#_tolerances
where od_upper_limit >= #temp_od# , od_lower_limit <= #temp_od#
</cfquery>

<cfparam name="variables.od_tolerance" default="#qtolerance.od_tolerance#">
<cfparam name="variables.id_tolerance" default="#qtolerance.id_tolerance#">
<cfparam name="variables.thk_tolerance" default="#qtolerance.thk_tolerance#">

<cfif product_type contains "isopress">

<cfif qtolerance.od_percentage eq "yes">
<cfset variables.od_tolerance = temp_od * qtolerance.od_tolerance>
<cfelse>
<cfset variables.od_tolerance = qtolerance.od_tolerance>
</cfif>

<cfif qtolerance.id_percentage eq "yes">
<cfset variables.id_tolerance = temp_od * qtolerance.id_tolerance>
<cfelse>
<cfset variables.id_tolerance = qtolerance.id_tolerance>
</cfif>

<cfset variables.thk_tolerance = qtolerance.thk_tolerance>

</cfif>

<cfif attributes.product eq "isopress_rectx" or attributes.product eq "isopress_lsect">
<cfif temp_thk lt 1.5>
<cfelseif temp_thk lte 3>
<cfset variables.thk_tolerance = 0.020>
<cfelseif temp_thk lte 6>
<cfset variables.thk_tolerance = 0.050>
<cfelseif temp_thk lte 12>
<cfset variables.thk_tolerance = 0.100>
<cfelseif temp_thk lte 18>
<cfset variables.thk_tolerance = 0.200>
</cfif>
</cfif>

<cfif attributes.measure eq "metric">

<cfset variables.od_tolerance = variables.od_tolerance * 25.4>
<cfset variables.id_tolerance = variables.id_tolerance * 25.4>
<cfset variables.thk_tolerance = variables.thk_tolerance * 25.4>

</cfif>



More discussions in ColdFusion


adobe

Comments

Popular posts from this blog

Thread: PKI Client 5.00 install (for eToken Pro)

ATmega2560-Arduino Pin Mapping

Crossfader Arduino Tutorial