Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
rohitgupta_ey
Contributor II
Contributor II

Count Function in SQL not working from Qlikview

I have a simple select count sql statement which is not working from qlikview

SQL

Select
count(BusinessEntityID)
from [Person].[BusinessEntityAddress];

 

However same script is working from dbms.

I have used OLEDB connect statement

1 Solution

Accepted Solutions
rohitgupta_ey
Contributor II
Contributor II
Author

yes @mfchmielowski that worked 
but without alias it does not work.

How does it work in db without alias

View solution in original post

3 Replies
mfchmielowski
Creator II
Creator II

Hi.

Is that full load statement or did you forgot to add load. The good practice is to name result column in sql statements. 

rohitgupta_ey
Contributor II
Contributor II
Author

yes @mfchmielowski that worked 
but without alias it does not work.

How does it work in db without alias

mfchmielowski
Creator II
Creator II

Hi. You need to tell qlik what column he had to load. In my case (MySQL as DB) code:
Table: load *; sql select count(id) from SomeTable; 
loads one column named count(id).