You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
WHEN TRIM(LOWER(is_active)) IN ('1', 'active', 'true', 'y', 'yes') THEN 'True'
40
+
WHEN TRIM(LOWER(is_active)) IN ('0', 'inactive', 'false', 'n', 'no') THEN 'False'
41
+
ELSE 'Unknown'
42
+
END AS is_active,
43
+
44
+
CASE
45
+
WHEN TRIM(account_created_date) LIKE'[A-Z][a-z][a-z] __, ____' THEN CONVERT(DATE,account_created_date)
46
+
WHEN TRIM(account_created_date) LIKE'[A-Z][a-z][a-z][a-z]% __, ____' THEN CONVERT(DATE,account_created_date)
47
+
WHEN TRIM(account_created_date) LIKE'____/__/__' THEN CONVERT(DATE,account_created_date)
48
+
WHEN TRIM(account_created_date) LIKE'____-__-__' THEN CONVERT(DATE,account_created_date)
49
+
50
+
WHEN TRIM(account_created_date) LIKE'__-__-____'AND TRY_CONVERT(INT, LEFT(account_created_date,2)) >12 THEN TRY_CONVERT(DATE, account_created_date, 105)
51
+
WHEN TRIM(account_created_date) LIKE'__-__-____'AND TRY_CONVERT(INT, SUBSTRING(account_created_date,4,2)) >12 THEN TRY_CONVERT(DATE, account_created_date, 110)
52
+
WHEN TRIM(account_created_date) LIKE'__/__/____'AND TRY_CONVERT(INT, LEFT(account_created_date,2)) >12 THEN TRY_CONVERT(DATE, account_created_date, 103)
53
+
WHEN TRIM(account_created_date) LIKE'__/__/____'AND TRY_CONVERT(INT, SUBSTRING(account_created_date, 4, 2)) >12 THEN TRY_CONVERT(DATE, account_created_date, 101)
0 commit comments