Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi all, I'm new to QlikView and I'm using SQL server DB for data, my question is the following: Can I execute complex SQL query directly in QlickView Script? By the term complex I mean a query containing (Count(), GroupBy, OrderBy, DATEADD() ) ....
Thank you,
Nabil
You can execute any valid SQL query you wish.
I've a valid one but it always failed in reading it
The correct way would be to read the raw table as it is using select without any where clause or grouping.
At the QlikView script level apply the logic that is there in the Query.
thanks,
Rajesh Vaswani
Rajesh Vaswani did you mean to reproduce all the SQL function that are already in the query with the QV functions?
Hi,
It should work as bill says.
Can you post your query here to check the issue.
Regards
ASHFAQ
Yes, again depends on your scenario as well as the architecture you have in place.
thanks,
Rajesh Vaswani
This is the query ,
select DATEADD(dd, DATEDIFF(DD, 0, X.actual_end_date_time),0), tile_run_state_id, Count(*) from X
Join X_state on X.state = X_state.tile_run_state_id
Where X_state.tile_run_state_id = 5
Group by DATEADD(DD, DATEDIFF(DD, 0, X.actual_end_date_time),0), tile_run_state_id
ORDER BY DATEADD(DD, DATEDIFF(DD, 0, X.actual_end_date_time),0) DESC
the query is working normally with SQL server Management Studio but not with QV
times out. As an alternative see if you can give a timeout value while creating the connecting string.
thanks,
Rajesh Vaswani