Search code examples
sqlms-access-2010truncated

Access SQL/query has truncated field at 25 characters?


I have this query in Access:

SELECT a.title, a.init, a.name, l.User AS CreatedBy,
     IIf(IsNull(l.Time),Null,DateAdd("s",l.Time,#3/1/1980#)) AS CreatedAt
     FROM (Reports AS a LEFT JOIN 
     (SELECT id, Min([time]) AS Mintime FROM AuditLog GROUP BY id) AS t
     ON a.id = t.id) 
     LEFT JOIN AuditLog AS l ON (t.mintime = l.time) AND (t.id = l.id)
     WHERE (((a.name) Like 'start*') AND ((a.Active)='Y'));

But for some reason a.name is truncated on every result in the query at 25 characters. Why is this? In the table Reports it is correct and shows the full name (25+ characters long).


Solution

  • I had two similar Name fields, I misread one and it indeed was truncated in the actual table.