Question volume with combination of Firebase and Flutter over time

0

Please login or register to vote for this query.

(click on this box to dismiss)

Stack Overflow

Q&A for professional and enthusiast programmers

SELECT c.Month, c.Type, c.Count
FROM (
  SELECT 
    DATEADD(MONTH, DATEDIFF(MONTH, 0, CreationDate), 0) AS [Month]
    , COUNT(DISTINCT P.Id) AS Count
    , 'Flutter' AS Type
  FROM Posts P
  WHERE P.PostTypeId = 1
    AND P.CreationDate > '2017-01-01'
    AND P.Tags LIKE '%firebase%' AND P.Tags LIKE '%flutter%' 
  GROUP BY DATEADD(MONTH, DATEDIFF(MONTH, 0, CreationDate), 0)
  
  UNION ALL SELECT 
    DATEADD(MONTH, DATEDIFF(MONTH, 0, CreationDate), 0) AS [Month]
    , COUNT(DISTINCT P.Id) AS Count
    , 'Swift' AS Type
  FROM Posts P
  WHERE P.PostTypeId = 1
    AND P.CreationDate > '2017-01-01'
    AND P.Tags LIKE '%firebase%' AND P.Tags LIKE '%swift%' 
  GROUP BY DATEADD(MONTH, DATEDIFF(MONTH, 0, CreationDate), 0)  
  
  UNION ALL SELECT 
    DATEADD(MONTH, DATEDIFF(MONTH, 0, CreationDate), 0) AS [Month]
    , COUNT(DISTINCT P.Id) AS Count
    , 'Android' AS Type
  FROM Posts P
  WHERE P.PostTypeId = 1
    AND P.CreationDate > '2017-01-01'
    AND P.Tags LIKE '%firebase%' AND P.Tags LIKE '%android%' 
  GROUP BY DATEADD(MONTH, DATEDIFF(MONTH, 0, CreationDate), 0)  
  
  UNION ALL SELECT 
    DATEADD(MONTH, DATEDIFF(MONTH, 0, CreationDate), 0) AS [Month]
    , COUNT(DISTINCT P.Id) AS Count
    , 'JavaScript' AS Type
  FROM Posts P
  WHERE P.PostTypeId = 1
    AND P.CreationDate > '2017-01-01'
    AND P.Tags LIKE '%firebase%' AND P.Tags LIKE '%javascript%' 
  GROUP BY DATEADD(MONTH, DATEDIFF(MONTH, 0, CreationDate), 0)    
) as c
ORDER BY [MONTH] DESC

Enter Parameters

Options:
Switch sites:
loading Hold tight while we fetch your results