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
For “Oracle” to “SQL Server” the “IN” is getting replaced with “dbo.IN” which isn’t going to work, trying to do many conversions and would like to use the command line tool instead of the online version.
Test version SQLines 3.1.113 - Windows 32-bit, 5.3 MB, July 02, 2018
(^^ is there a newer build for windows?)
Online converter works without issue without creating correct output.
Input
WITH George AS (SELECT B.*
FROM TABLE1 B
INNER JOIN TABLE2 T2 ON
1=1
AND T2.AGENCY = B.AGENCY
AND T2.REC_GROUP = B.REC_GROUP
AND T2.REC_TYPE = B.REC_TYPE
AND T2.REC_SUB_TYPE = B.REC_SUB_TYPE
AND T2.REC_CATEGORY = B.REC_CATEGORY
AND T2.REC_GROUP IN ('1','2','3','4')
AND T2.REC_TYPE IN ('1','2','3','4')
AND
(
(
T2.REC_GROUP ||
'/' ||
T2.REC_TYPE ||
'/' ||
T2.REC_SUB_TYPE||
'/' ||
T2.REC_CATEGORY IN ( '1','2','3','4' )
)
OR
(
T2.REC_GROUP||
'/' ||
T2.REC_TYPE = 'GEORGE'
)
)
WHERE
1=1
AND B.AGENCY = (SELECT AGENCY FROM PARAMS)
AND UPPER(B.B1_ALT_ID) = (SELECT capid FROM PARAMS)
)
SELECT * FROM GEORGE
Output:
WITH George AS (SELECT B.*
FROM TABLE1 B
INNER JOIN TABLE2 T2 ON
1=1
AND T2.AGENCY = B.AGENCY
AND T2.REC_GROUP = B.REC_GROUP
AND T2.REC_TYPE = B.REC_TYPE
AND T2.REC_SUB_TYPE = B.REC_SUB_TYPE
AND T2.REC_CATEGORY = B.REC_CATEGORY
AND T2.REC_GROUP dbo.IN ('1','2','3','4')
AND T2.REC_TYPE dbo.IN ('1','2','3','4')
AND
(
(
ISNULL(T2.REC_GROUP, '') +
'/' +
ISNULL(T2.REC_TYPE, '') +
'/' +
ISNULL(T2.REC_SUB_TYPE, '')+
'/' +
ISNULL(T2.REC_CATEGORY, '') dbo.IN ( '1','2','3','4' )
)
OR
(
ISNULL(T2.REC_GROUP, '')+
'/' +
ISNULL(T2.REC_TYPE, '') = 'GEORGE'
)
)
WHERE
1=1
AND B.AGENCY = (SELECT AGENCY FROM PARAMS)
AND UPPER(B.B1_ALT_ID) = (SELECT capid FROM PARAMS)
)
SELECT * FROM GEORGE
The text was updated successfully, but these errors were encountered:
For “Oracle” to “SQL Server” the “IN” is getting replaced with “dbo.IN” which isn’t going to work, trying to do many conversions and would like to use the command line tool instead of the online version.
Test version SQLines 3.1.113 - Windows 32-bit, 5.3 MB, July 02, 2018
(^^ is there a newer build for windows?)
Online converter works without issue without creating correct output.
Input
Output:
The text was updated successfully, but these errors were encountered: