SHARE
TWEET

Untitled

a guest Sep 13th, 2017 50 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. declare @string varchar(1000), @getPreviousDate date
  2. select @getPreviousDate = dateadd(day,datediff(day,1,GETDATE()),0)
  3. select @string =
  4. '
  5. SELECT * FROM openquery(kelkoospark,''SELECT count(*) from returning_users_device_types WHERE [date] = @getPreviousDate'')
  6. '
  7. select @string
  8. --EXEC (@string)
RAW Paste Data
Top