﻿<?xml version='1.0' encoding='UTF-8'?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/"><channel><title>Teradata Forums / Teradata  / Teradata Database  / Integer Vs Varchar in joins - Performance Impact / 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>Wed, 03 Dec 2008 15:41:21 GMT</lastBuildDate><ttl>20</ttl><item><title>RE: Integer Vs Varchar in joins - Performance Impact</title><link>http://www.teradata.com/teradataforum/Topic12355-9-1.aspx</link><description>Hi,Do u mean VLI for variable length input.....If yes then it's true....while dealing with varchar system has to vary length of storage continuously.....And if we deal with large volume of data we can see the overhead with such data.And if u want to see to this in practical way then look at multi value compression....Due to the same reason MVC doesn't allow compression on varchar....Regards,Subhash</description><pubDate>Fri, 01 Aug 2008 09:39:57 GMT</pubDate><dc:creator>gander_ss</dc:creator></item><item><title>RE: Integer Vs Varchar in joins - Performance Impact</title><link>http://www.teradata.com/teradataforum/Topic12355-9-1.aspx</link><description>IMHO, the cost difference between varchar and integer in comparing the column values would be miniscule.  The cost of the join will be overwhelmingly dominated by other factors.</description><pubDate>Wed, 30 Jul 2008 13:40:30 GMT</pubDate><dc:creator>Jim Chapman</dc:creator></item><item><title>RE: Integer Vs Varchar in joins - Performance Impact</title><link>http://www.teradata.com/teradataforum/Topic12355-9-1.aspx</link><description>Hi All,Thanks for the inputs!!!I'm not considering scenarios where i would be using substr or any concatenation etc.(Other factors like Data volume, any kind of indexes created can also be considered the same for both cases)From the inputs i could see that the performance impact is attributed to character column being of variable length.Subash,From the point i guess this performance impact would be seen even in queries without join when we deal with Varchar columns.Can you please let me know how variable length column is affecting query performance?(Is it becos it has to read the VLI and fetch data? Is this a significant overhead when we deal with huge data volume?)Regards,Annal T</description><pubDate>Wed, 30 Jul 2008 08:36:53 GMT</pubDate><dc:creator>Annal Tamizhnambi</dc:creator></item><item><title>RE: Integer Vs Varchar in joins - Performance Impact</title><link>http://www.teradata.com/teradataforum/Topic12355-9-1.aspx</link><description>Yes joins on integer and varchar affects the performance.As varchar is continuously vary in character lenght  and  integer doe not.And for any DB it is always easy to operate on fixed lenght object as compare to varying one.If you will use char on the place of varchar then u will see that there the difference in performane of char and integer will decrease.Regards,Subhash</description><pubDate>Wed, 30 Jul 2008 08:23:48 GMT</pubDate><dc:creator>gander_ss</dc:creator></item><item><title>RE: Integer Vs Varchar in joins - Performance Impact</title><link>http://www.teradata.com/teradataforum/Topic12355-9-1.aspx</link><description>Hello,It depends on numerous factors such as data, data volume, indexes defined on both tables and type of join used. And logically speaking yes it will affect the performance. And the worst scenario will be joining on the SUBSTR( ).HTH.Regards,Adeel</description><pubDate>Wed, 30 Jul 2008 03:42:59 GMT</pubDate><dc:creator>Adeel.Chaudhry</dc:creator></item><item><title>Integer Vs Varchar in joins - Performance Impact</title><link>http://www.teradata.com/teradataforum/Topic12355-9-1.aspx</link><description>Hi,I would like to know if there would be any performance impact when we join based on Varchar columnsand when we join based on Integer columns.Case 1: Table1 and Table 2 has EmployeeId as varchar(15)Select Table1.A,Table2.B.... from Table1 , Table 2 Where Table1.Employee = Table2.EmployeeCase 2: Table1 and Table 2 has EmployeeId as IntegerSelect Table1.A,Table2.B.... from Table1 , Table 2 Where Table1.Employee = Table2.EmployeeIn my case the varchar column size is only 15.I'm not able to load huge volumes of data into these two tables.With the sample data that i could load, im not able to see any performance difference between the two.I would like to know if there will be a performance difference.If someone can give comments on the above scenario it will be really useful.(Pointers to any thoeretical explanation in any documens would also be very helpful)Regards,Annal T</description><pubDate>Wed, 30 Jul 2008 03:26:31 GMT</pubDate><dc:creator>Annal Tamizhnambi</dc:creator></item></channel></rss>