- SELECT NTABLE = A.NAME, OTABLE = B.NAME
- FROM INTFSIMSNEW..SYSOBJECTS A
- LEFT JOIN INTFSIMS..SYSOBJECTS B
- ON A.NAME = B.NAME
- WHERE ISNULL(B.NAME, '') = ''
- AND A.XTYPE = 'U'
- UNION ALL
- SELECT NTABLE = B.NAME, OTABLE = A.NAME
- FROM INTFSIMS..SYSOBJECTS A
- LEFT JOIN INTFSIMSNEW..SYSOBJECTS B
- ON A.NAME = B.NAME
- WHERE ISNULL(B.NAME, '') = ''
- AND A.XTYPE = 'U'
- ORDER BY 1, 2
- SELECT NTABLE = A.NAME, OTABLE = B.NAME
- FROM INTFSIMSNEW..SYSOBJECTS A
- LEFT JOIN INTFSIMS..SYSOBJECTS B
- ON A.NAME = B.NAME
- WHERE ISNULL(B.NAME, '') = ''
- AND A.XTYPE = 'U'
- UNION ALL
- SELECT NTABLE = B.NAME, OTABLE = A.NAME
- FROM INTFSIMS..SYSOBJECTS A
- LEFT JOIN INTFSIMSNEW..SYSOBJECTS B
- ON A.NAME = B.NAME
- WHERE ISNULL(B.NAME, '') = ''
- AND A.XTYPE = 'U'
- ORDER BY 1, 2