[Q17-Q33] Updated May-2026 Test Engine to Practice Test for PDII-JPN Exam Questions and Answers!

Share

Updated May-2026 Test Engine to Practice Test for PDII-JPN Exam Questions and Answers!

Certification Sample Questions and Practice Exam

NEW QUESTION # 17
開発者はサンドボックスでテストの失敗を確認できますが、本番環境では確認できません。サンドボックスが作成されて以来、コードまたはメタデータの変更がいずれの環境に対しても積極的に行われていません。
問題を解決するために確認する必要がある考慮事項はどれですか?

  • A. Apex クラスが同じ API バージョンであることを確認します。
  • B. サンドボックスが本番環境と同じリリースであることを確認してください。
  • C. Process Builder プロセスが非アクティブであることを確認します。
  • D. ワークフロー ルールが非アクティブであることを確認します。

Answer: B


NEW QUESTION # 18
ABC Company には、複数の広範なデータベース操作と Web サービスの呼び出しを行う Apex プロセスがあります。データベース プロセスと Web サービスは、実行に時間がかかる場合があり、順番に実行する必要があります。
開発者は、ガバナ制限やシステム制限に遭遇することなく、この Apex コードをどのように記述すればよいでしょうか?

  • A. Apex スケジューラを使用して、各プロセスをスケジュールします。
  • B. Queueable Apex を使用してジョブをチェーンし、順番に実行します。
  • C. プロセスとコールアウトごとに複数の @future メソッドを使用します。
  • D. Limits クラスを使用して、ガバナーの制限に達したらプロセス全体を停止します。

Answer: D


NEW QUESTION # 19
プラットフォーム イベントが Salesforce 組織で定義された後、イベントを発行できるメカニズムはどれですか? 2つの答えを選択してください

  • A. 内部アプリは送信メッセージを使用できます
  • B. 外部アプリは標準のストリーミング API を使用できます。
  • C. 外部アプリにはカスタム Apex Web サービスが必要です。
  • D. 内部アプリは Process Builder を使用できます。

Answer: B,D

Explanation:
Explanation
internal apps can use processes, flows, or Apex to publish platform event messages from a Salesforce app.
Process Builder is a tool that lets you automate business processes by creating processes. You can use Process Builder to publish platform event messages when a record changes or when a platform event occurs.
external apps can use Salesforce APIs to publish platform event messages. You can use any Salesforce API to create platform events, such as SOAP API, REST API, or Bulk API. The Streaming API is a Salesforce API that lets you push a stream of notifications from Salesforce to external apps. You can use the Streaming API to publish platform event messages by creating records of your event type.
Therefore, using Process Builder and Streaming API are two mechanisms to publish platform event messages after a platform event is defined in a Salesforce org.
https://developer.salesforce.com/docs/atlas.en-us.platform_events.meta/platform_events/platform_events_publis


NEW QUESTION # 20
Apexトリガは、営業担当者が商談を獲得するたびにOrder__cレコードを作成します。最近、このトリガによって2つの注文が作成されています。開発者がこれをトラブルシューティングするための最適な方法は何ですか?

  • A. Apex トリガーの Apex テストクラスを実行して、コードに十分なコード カバレッジが残っていることを確認します。
  • B. すべての営業担当者に対してデバッグ ログを設定し、ログでエラーと例外を監視します。
  • C. すべてのフローを無効にし、フローを 1 つずつ再度有効にして、どのフローがエラーの原因であるかを確認します。
  • D. コードに system.debug() ステートメントを追加し、開発者コンソールのログを使用してコードをトレースします。

Answer: D

Explanation:
When a trigger unexpectedly executes twice (recursion), it is typically due to the Salesforce Order of Execution. A common cause is a workflow rule, process, or flow updating the same record that initiated the transaction, which re-triggers the original Apex trigger. To identify exactly where this second execution is being initiated, the most effective technique is to use system.debug() statements in conjunction with the Developer Console logs (Option D).
By placing debug statements at the start of the trigger (e.g., System.debug('Trigger Fired');), the developer can examine the execution log to see how many times that line appears. More importantly, the execution log provides a hierarchical "trace" of the entire transaction. The developer can look for entries like FLOW_CREATE_INTERVIEW or WF_RULE_EVAL_BEGIN between the two trigger execution blocks.
This trace reveals exactly which automation (Flow, Workflow, or another Trigger) caused the record to be updated a second time.
Option A is inefficient and disruptive to production environments. Option B is too broad and doesn't provide the internal execution context. Option C checks for code validity but does not diagnose runtime logic issues in a live environment. Tracing the execution through logs is the standard programmatic way to debug recursion and side effects in Salesforce.


NEW QUESTION # 21
Salesforce ユーザーは、アカウントを保存するときに常に「トリガーの深さが最大値を超えました」というエラーを受け取ります。開発者はこのエラーをどのように修正できるでしょうか?

  • A. トリガー ロジックを 2 つの別々のトリガーに分割します。
  • B. 3zure アノテーションを使用するようにトリガーを変換し、後続のトリガー呼び出しを Account オブジェクトにチェーンします。
  • C. L=MultiThread=true アノテーションを使用するようにトリガーを変更します。
  • D. ヘルパー クラスを使用して、トリガーが初めて起動されたときにブール値を TRUE に設定し、ブール値が FALSE の場合にのみ起動されるようにトリガーを変更します。

Answer: D

Explanation:
A common solution to the "Maximum trigger depth exceeded" error is to use a static variable in a helper class. The variable acts as a switch to ensure the trigger logic only executes once per transaction, preventing recursive trigger calls.
References: Salesforce Developer Blog - Avoiding Recursive Trigger Calls


NEW QUESTION # 22
カスタムインターフェースの一部として、開発者チームはさまざまな新しい Lightning Web コンポーネントを作成します。各コンポーネントはトースト メッセージを使用してエラーを処理します。開発が完了すると、すべてのコンポーネントが同じ Lightning ページに追加されます。
受け入れテスト中に、コンポーネントの読み込み中にエラーが発生したときに表示されるトースト メッセージの長いチェーンについてユーザーから苦情が寄せられました。
ユーザー エクスペリエンスを向上させるために開発者が実装する必要がある 2 つのテクニックはどれですか?
2 つの答えを選択してください

  • A. Lightning Web コンポーネントを使用して、すべてのエラーを集計して表示します
  • B. <tamplate> タグを使用して、インプレース エラー メッセージを表示します。
  • C. window.alert() メソッドを使用してエラー メッセージを表示します
  • D. 各コンポーネントの public プロパティを使用して、エラー メッセージを表示します。

Answer: A,D

Explanation:
The scenario describes a common issue when multiple components are used on the same Lightning page and each component manages its error handling independently, leading to a "long chain of toast messages" which can be overwhelming for users.
To improve user experience, the developers can implement the following techniques:
A: Use a Lightning web component to aggregate and display all errors: This method involves creating a centralized component responsible for handling all error messages. This component would receive error notifications from other components and then display them in a user-friendly manner. The benefit of this approach is that it provides a single, consistent interface for error messages, reducing the clutter and confusion that can be caused by multiple toasts.
D: Use public properties on each component to display the error messages: By using public properties, components can expose their error states to a parent or orchestrating component, which can then display these errors in a single, consolidated way. This avoids the issue of multiple toast notifications and allows for a more integrated error handling experience.
The other options presented are less ideal:
B: Using the window.alert() method is not recommended in a professional Salesforce environment as it is considered a disruptive way to show errors and does not align with the Salesforce Lightning design system.
C: Using a <template> tag to display in-place error messages could be a viable option for displaying error messages within the component itself, but it does not address the issue of multiple errors stacking up from different components as described in the scenario.
References:
For building a centralized error handling component: Lightning Web Components Developer Guide - Error Handling For implementing public properties: Lightning Web Components Developer Guide - Public Properties


NEW QUESTION # 23
Apex トリガと Apex クラスは、ケースが変更されるたびにカウンタ Edit_Count_c を増やします。

ケース オブジェクトの新しいプロセスは、ケースが作成または更新されたときに実稼働環境で作成されたばかりです。< プロセスが作成されてから、ケースの編集時にカウントが 1 を超えてインクリメントされていることが報告されています。
問題を解決する Apex コードの変更はどれですか?

  • A.
  • B.
  • C.
  • D.

Answer: C


NEW QUESTION # 24
階層のカスタム設定を定義できるレベルは? (3つ選んでください。)

  • A. プロファイル
  • B. ユーザー
  • C. ロール
  • D. 組織
  • E. グループ

Answer: A,B,D


NEW QUESTION # 25
企業には、データ設定の一部として取引先レコードを作成するさまざまな単体テスト方法があります。新しい必須フィールドがアカウントに追加され、すべての単体テストが失敗するようになりました。
開発者にとって問題を解決する最適な方法は何ですか?

  • A. 単体テスト用のアカウントを作成する単一の場所として機能する TestDataFactory クラスを作成し、そこに必要なフィールドを設定します。
  • B. すべての単体テストのデータ設定に必須フィールドを追加します。
  • C. 必須フィールドを、システム管理者プロファイルを除外する検証ルールに変更します。
  • D. アカウントに挿入前トリガーを追加して、必須フィールドの値を設定します。

Answer: A

Explanation:
The optimal way for a developer to fix the issue of failing unit tests due to a new required field on the Account is to create a TestDataFactory class that serves as the single place to create Accounts for unit tests and set the required field there. This way, the developer can avoid code duplication, reduce maintenance effort, and ensure consistency across all the unit tests that need Account records. Adding the required field to the data setup for all of the unit tests would be tedious and error-prone. Adding a before insert trigger on Account to set the value of the required field would be a workaround that might affect the business logic and the data quality. Changing the required field to be a validation rule that excludes the System Administrator profile would be a security risk and a bad practice. Reference: [Understanding Test Data], [Test Data Factory]


NEW QUESTION # 26
開発者は、ユーザが Apex メソッドを呼び出して取引先の検索に使用されるテキスト値を入力できるようにする Lightning Web コンポーネント マットを作成しました。Apex メソッドは、適用するアカウントのリストを返し、JavaScript イベントハンドラから命令的に呼び出されます。

Apex メソッドが正しく機能するために、開発者は次の 2 つの変更を行う必要があります。
2 つの答えを選択してください

  • A. @AuraEnabled を 11 行目と 12 行目に追加します。
  • B. @AuraEnabled を行 01 に追加します。
  • C. @AuraEnabled を行 03 に追加します。
  • D. @AuraEnabled を行 09 に追加します。

Answer: A,C


NEW QUESTION # 27
Azure コンポーネントを表す次のコード スニペットを検討してください。

コンポーネントをクイック アクションとして使用できるようにするために、開発者が実装できる 2 つのインターフェイスはどれですか?
2つの答えを選択してください

  • A. Force:lightningQuickActionWithoutHeader
  • B. 強制:hasRecordId
  • C. ライトニング QuickActionAPI
  • D. hasObjectName を強制する
  • E. Force:lightningQuicAction

Answer: A,E


NEW QUESTION # 28
開発者は、どのプロファイルとユーザーがどのシークレットにアクセスできるかを指定できるシークレットデータを保存する方法を見つけるよう求められています。このデータの保存には何を使用すべきでしょうか?

  • A. カスタムメタデータ
  • B. 静的リソース
  • C. カスタム設定
  • D. System.Cookie クラス

Answer: C

Explanation:
When a requirement involves storing configuration or "secret" data that needs to vary based on the specific user or profile, Hierarchy Custom Settings (Option C) are the correct choice. Unlike Custom Metadata (Option B), which is available to the entire organization regardless of the user, Hierarchy Custom Settings use a built-in logic to provide values based on the "most specific" level defined.
The hierarchy follows a specific order: User > Profile > Organization. If a secret key is defined at the User level, that value is returned for that specific user. If not, the system looks for a value defined at the user's Profile level, and finally falls back to the Organization-wide default. This allows a developer to store sensitive keys or flags and restrict or vary them dynamically based on the current user's identity.
Custom Metadata is better suited for application-wide configurations that need to be deployable via packages, but it lacks the granular per-user/per-profile override capability inherent to Hierarchy Custom Settings. Static Resources (Option A) are public to anyone with access to the resource, and Cookies (Option D) are stored on the client side, making them insecure for "secret" data. Therefore, Custom Settings provide the best balance of security and hierarchical flexibility for this use case.


NEW QUESTION # 29
Java
trigger AssignOwnerByRegion on Account ( before insert, before update ) { List<Account> accountList = new List<Account>(); for( Account anAccount : trigger.new ) { Region__c theRegion = [ SELECT Id, Name, Region_Manager__c FROM Region__c WHERE Name = :anAccount.Region_Name__c
];
anAccount.OwnerId = theRegion.Region_Manager__c;
accountList.add( anAccount );
}
update accountList;
}
上記のトリガーについて考えてみましょう。ベストプラクティスに準拠するために、開発者はこのトリガーにどのような2つの変更を加えるべきでしょうか?30

  • A. List accountList.32 の代わりに Map accountMap を使用します。
  • B. accountListを更新する最後の行は不要なので削除します。31
  • C. マップを使用して、Id.33 による Region__c クエリの結果をキャッシュします。
  • D. Re34gion__c クエリをループの外側に移動します。

Answer: B,D

Explanation:
The provided trigger contains two major violations of Salesforce Apex best practices.
* SOQL inside a Loop (Option D): The query for Region__c is located inside the for loop. If 200 accounts are updated at once, the trigger will attempt to run 200 queries, immediately hitting the governor limit of 100 SOQL queries per t35ransaction. To fix this, the developer must "bulkify" the trigger by collecting all the Region_Name__c values into a Set, performing a single query outside the loop, and storing the results in a Map for quick access.
* Redundant DML in a Before Trigger (Option A): This is a before insert and before update trigger. In the "before" context, changes made to Trigger.new records are automatically committed to the database when the trigger finishes. Adding an explicit update accountList; is not only unnecessary but will cause the trigger to re-fire (recursion), leading to performance issues and potential "Maximum stack depth" errors.
By removing the redundant DML and moving the query outside the loop, the trigger becomes efficient, scalable, and follows the platform's execution model correctly.


NEW QUESTION # 30
Lightning Web コンポーネントはシステム内に存在し、コンテキスト内のレコードに関する情報をメダルとして表示します。Salesforce 管理者は、Lightning アプリケーションビルダー内でこのコンポーネントを使用する必要があります。開発者が XML リソースファイル内で構成する必要がある 2 つの設定はどれですか?
2 つの答えを選択してください

  • A. ターゲットを lightning_AppPage に指定します
  • B. ターゲットを lightning_RecordPage に指定します
  • C. IsVisible 属性を true に設定します。
  • D. IsExused=d 属性を true に設定します。

Answer: B,D

Explanation:
The two settings that the developer should configure within the xml resource file are to specify the target to be lightning_RecordPage and to set the IsExposed attribute to true. The target element defines where the component can be used, and the lightning_RecordPage value indicates that the component can be used on a Lightning record page. The IsExposed attribute determines whether the component is available in tools such as App Builder or Experience Builder, and setting it to true exposes the component to these tools. The IsVisible attribute is not a valid answer, as it is not a valid attribute for the xml resource file, and it does not affect the availability of the component. The lightning_AppPage value is not a valid answer, as it indicates that the component can be used on a Lightning app page, not a Lightning record page. Reference: [Configure Components for Lightning Pages and the Lightning App Builder], [Lightning Web Components Developer Guide]


NEW QUESTION # 31
開発者は、注文品目の数量、単価、および合計を表示する Lightning Web コンポーネントを構築しています。合計は、数量に単価を掛けて動的に計算されます。

合計を表示するには何を追加する必要がありますか?

  • A. テンプレートに Total: {quantity * UnitPrice} を追加します。
  • B. get total() { return quantity * unitPrice;} を JavaScript に追加し、Total: {total} をテンプレートに追加します。
  • C. 合計を追加します。{複数の数量、y 単価)} テンプレートで。
  • D. calculate Total() {return quantity * unitPrice;} を javaScript に追加し、Total : {calculate Total()} をテンプレートに追加します。

Answer: D


NEW QUESTION # 32
開発者は、商談ステージが変化したときに顧客に自動的に電子メールを送信するソリューションを構築するように求められます。ソリューションは、1 日あたり 10,000 件の電子メールを処理できるように拡張する必要があります。電子メールを送信する基準は、特定の条件が満たされた後に評価する必要があります。
これを達成するための最適な方法は何でしょうか?

  • A. MassEmailMEssage () を Apex トリガで使用します。
  • B. Apex トリガで SingleEmailMessage() を使用します。
  • C. ワークフロー電子メール アラートを使用します。
  • D. Flow Builder で電子メール アラートを使用します。

Answer: D

Explanation:
Using an Email Alert with Flow Builder allows for scalable solutions that can handle large volumes of emails, and it offloads the processing from Apex to Salesforce's declarative automation tools. This approach is also bulk-safe, as it does not rely on Apex code that could hit governor limits.References: Flow Builder - Email Alerts


NEW QUESTION # 33
......

Certification dumps Salesforce Developers PDII-JPN guides - 100% valid: https://www.actualtestsquiz.com/PDII-JPN-test-torrent.html

100% Pass Your PDII-JPN at First Attempt with ActualTestsQuiz: https://drive.google.com/open?id=1Jr5UcHXHnwSkUL8QQ9lqCMX4UlOE9vIa