AnsweredAssumed Answered

PI OLEDB piunitbatch SQL

Question asked by Dubus on Dec 3, 2018
Latest reply on Dec 3, 2018 by gregor

Hi,

 

We have trouble in select in pibatch..piunitbatch through the PI OLEDB :

With batchuid constraint, we have data

with batchid constraint, we don't have data

 

 

select *fromopenquery(PDW,'SELECT * from pibatch..piunitbatch WHERE batchuid = ''0f9b47f7-a020-4cb3-9263-f21bb42abf7d'' and starttime between ''2017-11-03'' and ''2017-11-04'' ') : 51 Rows.

select *fromopenquery(PDW,'SELECT * from pibatch..piunitbatch WHERE batchid like ''%PACK%'' and starttime between ''2017-11-03'' and ''2017-11-04'' ')

: directly 0 row

select *fromopenquery(PDW,'SELECT * from pibatch..piunitbatch WHERE batchid = ''20171103.100858P-UNPACKING-EPACDPA044'' and starttime between ''2017-11-03'' and ''2017-11-04'' ') : directly 0 row

 

 

Does anyone have an explanation ?

 

Thank you

 

PDW is the Linked Server to piarchive.

 

Outcomes