Skip to main content

Hi,

I will find how many different ID are for one GARDSNR and BRUKSNR.

I've correct answer with Cumulative (3), but in Complete and Summary Count is 5 (sholud be 3):

Parameters used for StatisticsCalculator:

Group by: GARDSNR BRUKSNR

Attribute to analyse: ID

Total Count attribute: Count

Thanks in advantage:)

 

 

Hi @elzbietalekve, can you please provide a screenshot of the data before the StatisticsCalculator?

 


Hi @elzbietalekve, we cannot say anything about if the result is correct, since your screenshot (pdf) shows only the first 3 records. Are you sure that the source table has just 3 records of (BRUKSNR=2, GARDSNR=14)? To determine if the result is correct or not, you will have to check all the records in the table.


Hi @elzbietalekve, we cannot say anything about if the result is correct, since your screenshot (pdf) shows only the first 3 records. Are you sure that the source table has just 3 records of (BRUKSNR=2, GARDSNR=14)? To determine if the result is correct or not, you will have to check all the records in the table.

The StatisticsCalculator with the same parameters setting as yours generates the following result from this table, and the result is correct.

 

BRUKSNR,GARDSNR,ID
2,14,169626054
2,14,169626336
2,14,169627390
3,15,169626336
2,14,169627390
3,15,169626336
2,14,169627390

0684Q00000ArMH3QAN.png


When I use this sentence in SQLCreator:

SELECT MATRIKKELENHET.GARDSNR, MATRIKKELENHET.BRUKSNR, TEIG.ID, TEIG.NORD, TEIG.OST

 

FROM TEIG, MATRIKKELENHET, TEIGFORMATRIKKELENHET

 

WHERE TEIG.ID = TEIGFORMATRIKKELENHET.TEIGID

 

AND TEIGFORMATRIKKELENHET.MATRIKKELENHETID = MATRIKKELENHET.ID

 

and ((MATRIKKELENHET.GARDSNR = 16 and MATRIKKELENHET.BRUKSNR = 1245)

 

or (MATRIKKELENHET.GARDSNR = 14 and MATRIKKELENHET.BRUKSNR = 2));I get the correct answer in Complete, Cumulative and Summary.

And when I use another program I can see that is only 3 records for 2/14.

But when I use this sentence:

SELECT MATRIKKELENHET.GARDSNR, MATRIKKELENHET.BRUKSNR, TEIG.ID, TEIG.NORD, TEIG.OST

 

FROM TEIG, MATRIKKELENHET, TEIGFORMATRIKKELENHET

 

WHERE TEIG.ID = TEIGFORMATRIKKELENHET.TEIGID

 

AND TEIGFORMATRIKKELENHET.MATRIKKELENHETID = MATRIKKELENHET.ID;

I get the strange Count = 5 in Complete and Summary.


I see that Pictures are not im mail: oadminelaantall-teigthis-is-from-the-sentence.pdf


I got all records from database and I've got just only 3 records for 14/2


Reply