<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns:mv="http://macVmlSchemaUri" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<meta name="Title" content="">
<meta name="Keywords" content="">
<meta name="Generator" content="Microsoft Word 15 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
        {font-family:"Cambria Math";
        panose-1:2 4 5 3 5 4 6 3 2 4;}
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:"MS Mincho";
        panose-1:2 2 6 9 4 2 5 8 3 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0in;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:Calibri;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:#0563C1;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:#954F72;
        text-decoration:underline;}
span.EmailStyle17
        {mso-style-type:personal;
        font-family:Calibri;
        color:windowtext;}
span.EmailStyle18
        {mso-style-type:personal-compose;
        font-family:Calibri;
        color:windowtext;}
span.msoIns
        {mso-style-type:export-only;
        mso-style-name:"";
        text-decoration:underline;
        color:teal;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;
        font-family:Calibri;}
@page WordSection1
        {size:8.5in 11.0in;
        margin:1.0in 1.0in 1.0in 1.0in;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1027"/>
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1"/>
</o:shapelayout></xml><![endif]-->
</head>
<body bgcolor="white" lang="EN-US" link="#0563C1" vlink="#954F72">
<div class="WordSection1">
<p class="MsoNormal"><span style="font-size:11.0pt">Greetings!<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt">I’ve had this error going on for the last 2 years or so (the cause seemed to be driven by adding a new Custom Field configuration). I’ve been on the 4.0 release for a while (upgraded to various versions through
 the 2.x and 3.x series). I hoped that it would fix itself when I migrated up to 4.4 (only done in test so far), but no such luck.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt">It is generated any time a ticket is shown through the web interface, so it’s a pretty frequent error!<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt"><o:p> </o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-size:11.0pt">Oct 16 17:40:36 helium postgres[4097]: [5-1] ERROR:  column "main.name" must appear in the GROUP BY clause or be used in an aggregate function at character 8<o:p></o:p></span></p>
<p class="MsoNormal" style="margin-left:.5in"><span style="font-size:11.0pt">Oct 16 17:40:36 helium postgres[4097]: [5-2] STATEMENT:  SELECT main.* FROM CustomFields main JOIN ObjectCustomFields ObjectCustomFields_1  ON ( ObjectCustomFields_1.CustomField =
 main.id )  WHERE (ObjectCustomFields_1.ObjectId = '33' OR ObjectCustomFields_1.ObjectId = '0') AND (main.Disabled = '0') AND (main.LookupType = 'RT::Queue-RT::Ticket-RT::Transaction')   GROUP BY main.id   ORDER BY MIN(ObjectCustomFields_1.SortOrder) ASC<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt">When this fails, it seems to also prevent the Custom Fields functionality from working at all, which is a bummer.
<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt">I tried deleting everything from CustomFields, CustomFieldValues, ObjectCustomFields, and ObjectCustomFieldValues, but this didn’t help.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt">Environment: FreeBSD 9.3 (migrating to 10.3), PostgreSQL 9.1 (migrating to 9.5), RT 4.0.24 (migrating to 4.4.1).
<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt">I did a new RT 4.4.1 build/database in a VM and compared the schemas between my upgraded RT database and the clean one, and I didn’t see significant differences in the CustomFields, CustomFieldValues, ObjectCustomFields,
 and ObjectCustomFieldValues tables.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt">Any suggestions on what I could do to help resolve this error?<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt">Thanks!<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Times New Roman"">-- <o:p></o:p></span></p>
<div>
<p class="MsoNormal"><span style="font-family:"Times New Roman"">Mike Fisher          
</span><a href="mailto:Michael_Fisher@urmc.rochester.edu"><span style="font-family:"Times New Roman"">Michael_Fisher@urmc.rochester.edu</span></a><span style="font-family:"Times New Roman"">             585-275-6884</span><span style="font-family:"MS Mincho""><o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-family:"Times New Roman"">University of Rochester                                                               School of Nursing<o:p></o:p></span></p>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
</div>
</body>
</html>