if len(df1.columns) != len(df2.columns):
raise ValueError('Column number mismatch')
for col1, col2 in zip(sorted(df1.columns), sorted(df2.columns)):
if col1 != col2:
raise ValueError('Column name mismatch')
if df1[col1].dtype != df2[col2].dtype:
raise ValueError('Column dtype mismatch')