private string [] GetPrimaryKeys (string catalog, string schema, string table)
{
if (cols.Length <= 0)
return new string [0];
ArrayList keys = null;
try {
keys = GetPrimaryKeysBySQLPrimaryKey (catalog, schema, table);
} catch (OdbcException) {
try {
keys = GetPrimaryKeysBySQLStatistics (catalog, schema, table);
} catch (OdbcException) {
}
}
if (keys == null)
return null;
keys.Sort ();
return (string []) keys.ToArray (typeof (string));
}