Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hey Everione,
About this code i get the result that o want to
Corrige_Medidor:
LOAD
DISTINCT
OID_METER,
VALUE_READ AS VALOR,
DATE_READ
RESIDENT TMP2
ORDER BY OID_METER,DATE_READ DESC ;
NoConcatenate
Exclude_Meter:
LOAD
DISTINCT
OID_METER,
VALOR,
PEEK(VALOR),
IF(VALOR - PEEK(VALOR)=0,OID_METER) AS EXCLUIR,
DATE_READ
RESIDENT Corrige_Medidor
ORDER BY OID_METER,DATE_READ DESC ;
drop table Corrige_Medidor;
Exclusao:
LOAD
OID_METER,
EXCLUIR
RESIDENT Exclude_Meter
WHERE Isnull(EXCLUIR)=0
ORDER BY OID_METER;
And i get this result:
But now i need to pick just the values on OID_METER that doent have correspondent on EXCLUIR.
I tried this:
Exclusao2:
LOAD
OID_METER,
EXCLUIR
RESIDENT Exclude_Meter
WHERE Isnull(EXCLUIR)=-1
ORDER BY OID_METER;
and this:
Exclusao2:
LOAD
OID_METER,
EXCLUIR
RESIDENT Exclude_Meter
WHERE EXCLUIR <> OID_METER
ORDER BY OID_METER;
even this:
Exclusao2:
LOAD
OID_METER,
EXCLUIR,
If (not exists (OID_METER,EXCLUIR)=-1, OID_METER)
RESIDENT Exclude_Meter
ORDER BY OID_METER;
but nothing worked. My OID_METER returns no record.
Someone could help me?
Hi,
I understand what im doing wrong
The problem was here
Exclusao:
LOAD
OID_METER,
EXCLUIR
RESIDENT Exclude_Meter
WHERE NOT EXISTS(EXCLUIR,OID_METER)=-1
ORDER BY EXCLUIR;
DROP TABLE Exclude_Meter;
Hi,
I understand what im doing wrong
The problem was here
Exclusao:
LOAD
OID_METER,
EXCLUIR
RESIDENT Exclude_Meter
WHERE NOT EXISTS(EXCLUIR,OID_METER)=-1
ORDER BY EXCLUIR;
DROP TABLE Exclude_Meter;