SOQLクエリから自動生成Map

来源:互联网 发布:在淘宝联盟上买东西吗 编辑:程序博客网 时间:2024/06/05 14:52
// Populate map from SOQL queryMap<ID, Account> m = new Map<ID, Account>([SELECT Id, Name FROM Account LIMIT 10]);// After populating the map, iterate through the map entriesfor (ID idKey : m.keyset()) {    Account a = m.get(idKey);    System.debug(a);}


0 0