Stringsql="SELECT C.COLUMN_NAME, C.COLUMN_TYPE, C.COLUMN_COMMENT, CU.CONSTRAINT_NAME FROM COLUMNS C LEFT JOIN KEY_COLUMN_USAGE CU ON CU.TABLE_SCHEMA = C.TABLE_SCHEMA AND CU.TABLE_NAME = C.TABLE_NAME AND CU.COLUMN_NAME = C.COLUMN_NAME WHERE C.TABLE_SCHEMA = '"+db_name+"' AND C.TABLE_NAME = '"+name+"'";
Stringsql="SELECT DISTINCT C.COLUMN_NAME, C.COLUMN_TYPE, C.COLUMN_COMMENT, CU.CONSTRAINT_NAME FROM COLUMNS C LEFT JOIN KEY_COLUMN_USAGE CU ON CU.TABLE_SCHEMA = C.TABLE_SCHEMA AND CU.TABLE_NAME = C.TABLE_NAME AND CU.COLUMN_NAME = C.COLUMN_NAME WHERE C.TABLE_SCHEMA = '"+db_name+"' AND C.TABLE_NAME = '"+name+"'";