/// <summary> /// returns list of queries /// </summary> /// <returns></returns> public string[] QueryNames() { string strAccessConn = GetConnectionString(filename); OleDbConnection conn = new OleDbConnection(strAccessConn); conn.Open(); DataTable schemaTable = conn.GetOleDbSchemaTable(OleDbSchemaGuid.Tables, null); conn.Close(); return(DataTableUtility.Strings(schemaTable, "TABLE_TYPE='VIEW'", "TABLE_name")); }
/// <summary> /// returns list of tables /// </summary> /// <returns>array of strings</returns> public override string[] TableNames() { string strAccessConn = GetConnectionString(filename); OleDbConnection conn = new OleDbConnection(strAccessConn); conn.Open(); DataTable tbl = conn.GetOleDbSchemaTable(OleDbSchemaGuid.Tables, null); conn.Close(); return(DataTableUtility.Strings(tbl, "TABLE_TYPE='TABLE'", "TABLE_name")); }