ephraimbuddy commented on code in PR #23444:
URL: https://github.com/apache/airflow/pull/23444#discussion_r864311303


##########
airflow/migrations/utils.py:
##########
@@ -35,7 +35,8 @@ def get_mssql_table_constraints(conn, table_name):
      FROM INFORMATION_SCHEMA.TABLE_CONSTRAINTS AS tc
      JOIN INFORMATION_SCHEMA.CONSTRAINT_COLUMN_USAGE AS ccu ON 
ccu.CONSTRAINT_NAME = tc.CONSTRAINT_NAME
      WHERE tc.TABLE_NAME = '{table_name}' AND
-     (tc.CONSTRAINT_TYPE = 'PRIMARY KEY' or UPPER(tc.CONSTRAINT_TYPE) = 
'UNIQUE')
+     (tc.CONSTRAINT_TYPE = 'PRIMARY KEY' or UPPER(tc.CONSTRAINT_TYPE) = 
'UNIQUE'
+     or UPPER(tc.CONSTRAINT_TYPE) = 'FOREIGN KEY')

Review Comment:
   Yea. Possible but it'll require editing released migrations. Where ever it 
was used, it compares to an upper case value. 
   In my opinion we should keep it with the `UPPER` case



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to