4 Replies Latest reply: Jan 29, 2015 9:28 AM by Rahul Yadav RSS

    script problem

      Dear All,

       

      How to user this SQL query in qlikview script :

       

       

      Select Level00,

        Level02,

      (

        SELECT TOP 1 Level2

        FROM demo m

        WHERE m.ProductCode = tb.ProductCode

        AND (

        m.StoreCode = sm.StoreCode

        OR m.StoreCode IS NULL

        )

        AND m.CreatedDate <= tb.CreatedOn

        ELSE 1 END)

        ORDER BY m.CreatedDate DESC

        ) AS 'Level2'

       

       

      FROM dbo.User(NOLOCK) umr

      INNER JOIN tempDemo tb ON tb.ModuleID = srm.ModuleID

       

       

      Please reply..

       

       

      Rahul