Skip to main content
Announcements
Introducing a new Enhanced File Management feature in Qlik Cloud! GET THE DETAILS!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

ms sql code convertion to qlikview script

Hello guys,

I would like to get help from you. Does exist any construction in qlikview script to realize the following sql code:

select td.Period, td.PeriodStart, td.PeriodEnd, td2.PaidDate, td2.DebitorID

  from tempDebitors td,

        tempDebitors td2

  where td2.PaidDate between td.PeriodStart and td.PeriodEnd

I don't know how to use two same tables (resident table ) as in sql code at once, because it doesn't have any joins. Table2 in qlikview file it's equal tempDebitors in sql.

Thanks for help.

2 Replies
SunilChauhan
Champion II
Champion II

between keyword not available in qlikview but it shuld work when write below code after connection string

table1

select td.Period, td.PeriodStart, td.PeriodEnd, td2.PaidDate, td2.DebitorID

  from tempDebitors td,

        tempDebitors td2

  where td2.PaidDate between td.PeriodStart and td.PeriodEnd

or inplace of where you can use below code

where td2.PaidDate >=td.PeriodStart and td2.PaidDate <= td.PeriodEnd.

you can take resident of above table

Load * ,

1 as Junk

resident table1

drop table table1;

hope this helps

Sunil Chauhan
Not applicable
Author

problem is that in my sql code i haven't any joins by fieldkey, but how i understand in Qlikview i should using fiedkeys