﻿<?xml version='1.0' encoding='UTF-8'?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/"><channel><title>Teradata Forums / Analytical Applications / Teradata   / Help Please, working with AVG / Latest Posts</title><generator>InstantForum.NET v4.1.4</generator><description>Teradata Forums</description><link>http://www.teradata.com/teradataforum/</link><webMaster>info@teradata.com</webMaster><lastBuildDate>Fri, 05 Sep 2008 19:34:13 GMT</lastBuildDate><ttl>20</ttl><item><title>RE: Help Please, working with AVG</title><link>http://www.teradata.com/teradataforum/Topic10826-5-1.aspx</link><description>You posed the very same question on 3/6 and it was answered to your satisfation. Why are you  asking the same questin again?http://www.teradata.com/teradataForum/Topic10827-9-1.aspx</description><pubDate>Fri, 21 Mar 2008 17:52:32 GMT</pubDate><dc:creator>rgs</dc:creator></item><item><title>RE: Help Please, working with AVG</title><link>http://www.teradata.com/teradataforum/Topic10826-5-1.aspx</link><description>Are you sure about your code ?I don't see any reference to A or B alias in the WHERE clause.</description><pubDate>Fri, 21 Mar 2008 11:42:01 GMT</pubDate><dc:creator>al1_24</dc:creator></item><item><title>Help Please, working with AVG</title><link>http://www.teradata.com/teradataforum/Topic10826-5-1.aspx</link><description>Hi all,I am trying to do a statement equivalent to the following one from Oracle;SELECT DISTINCT A.EMPLOYEE_NBRFROM EMPLOYEE_POSITION A, EMPLOYEE_POSITION_CTRL BWHERE (SELECT AVG(SALARY) FROM EMPLOYEE_POSITION) &amp;gt; ((SELECT AVG(SALARY) FROM EMPLOYEE_POSITION_CTRL) * .05)+ (SELECT AVG(SALARY) FROM EMPLOYEE_POSITION_CTRL)OR (SELECT AVG(SALARY) FROM EMPLOYEE_POSITION) &amp;lt; ((SELECT AVG(SALARY) FROM EMPLOYEE_POSITION_CTRL)-(SELECT AVG(SALARY) FROM EMPLOYEE_POSITION_CTRL) * .05)Basically I am trying to determine if the AVG of salary in table A is within 5 percent of table B.  It works for all other db's but in TD i get errors and i've tried different things with no luck.  The datatype is Float.   If somebody could help me i would sincerely appreciate it, were turning our wheels here.  For more info or to contact me directly please respond to this post.</description><pubDate>Thu, 06 Mar 2008 14:53:46 GMT</pubDate><dc:creator>mior66</dc:creator></item></channel></rss>