Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
AWS Degraded - You may experience Community slowness, timeouts, or trouble accessing: LATEST HERE
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

[resolved] NULL records for count(*) in tPostgresql_row

Hi,
I am executing a query using the tPostgressql_row component and passing the results on from that query to tLog row and a tPostgresqlOutput component.
The query is as follows:
"select
count(*),
\"PRS_ID\",
\"DATE\"
from
\"TABLE\"
where
\"public\".\"TABLE\".\"COLUMN_1\" = ?
and
\"public\".\"TABLE\".\"COLUMN_2\" = ?

group by
\"PRS_ID\",
\"DATE\" "

The component is set to use a Prepared Statement and seems to be working fine. The Schema is set to have 3 output rows - count, PRS_ID and DATE. The PRS_ID and DATE column load data just fine but I always get a NULL value for the count column.
While trouble shooting I tried aliasing the DATE column to DATE_D and had the schema column name set to DATE_D. The DATE_D column then contained NULL's too.
I tried populating the result set and then parsing it but the parse component doesn't output any rows - Going through the forums I saw that that is a bug when there is only 1 record in the result set.
Any ideas how I can solve this?
Thanks!
Labels (2)
10 Replies
_AnonymousUser
Specialist III
Specialist III

I do not know whats wrong with your job but normally this design should work.
But because you do not use prepared statements you can simplify your job with the tPostgresqlInput component.

Hi jlolling,
The method you suggested here to use txxxRow and tParseRcord set works great. However, I have a scenario like :
Say input is 100 records to txxxRow and in the select SQL of txxxRow finds a match for Only 90 records. So, it passes only 90 to tParseRecorset.
Question is :
                   How to collect that 10 UNUSED records ? Can you please sugest some way around.
Thanks,
Vimal