AnsweredAssumed Answered

How to display static value in PI ProcessBook from SQL Server via ODBC

Question asked by ArizonaDean on Mar 31, 2017
Latest reply on Apr 6, 2017 by ArizonaDean

I have a local instance of SQL Server 2005 on Windows 7. I've created an ODBC data source for use with PI ProcessBook 2015. I can't figure out how to get a value to display. Here's my query:

SELECT TOP (1) CAST (AuditTrail.Data1 AS numeric (5,2)) AS P1

FROM SUITE32.dbo.AuditTrail AuditTrail

WHERE (AuditTrail.SiteId=13188153)

ORDER BY AuditTrail.LogDate DESC

This works well in SQL Server Management Console and appears to be valid in the ProcessBook data source. I'm getting this error:


Can anyone tell me what I'm doing wrong?