| sql_orderby_seq [message #4056] | 
			Wed, 22 January 2014 14:09   | 
		 
		
			
				
				
				
					
						  
						David Lee
						 Messages: 44 Registered: June 2006 
						
					 | 
					Member  | 
					 | 
		 
		 
	 | 
 
	
		For a list1 screen, and possibly others, setting $sql_orderby_seq='desc' has no effect - the order is still asc. A workaround is adding desc to the end of the $sql_orderby, as in $sql_orderby='location desc' to sort by the location field in descending order. 
 
It may be best to remove $sql_orderby_seq completely, and let the sequence be defined in $sql_orderby, as that appears to be the way the existing code works.
		
		
		
 |  
	| 
		
	 | 
 
 
 | 
	
		
		
			| Re: sql_orderby_seq [message #4057 is a reply to message #4056] | 
			Wed, 22 January 2014 14:42   | 
		 
		
			
				
				
				
					
						  
						AJM
						 Messages: 2386 Registered: April 2006  Location: Surrey, UK
						
					 | 
					Senior Member  | 
					 | 
		 
		 
	 | 
 
	
		If you want to set the sort sequence for a particular LIST1 transaction then the correct way to do it is to set the 'Order By' field in the 'Update Task' screen. I have tested it, and it works perfectly. 
 
$sql_orderby_seq is there to allow toggling between 'asc' and 'desc' on whatever field is specified in $sql_orderby.
		
		
  Tony Marston 
http://www.tonymarston.net 
http://www.radicore.org
		
 |  
	| 
		
	 | 
 
 
 |