CertyRush
Đang tải...
C CertyRush
Câu hỏi free preview

Câu 75: DP-420: Designing and Implementing Cloud-Native Applications Using Microsoft Azure Cosmos DB

You have a database in an Azure Cosmos DB Core (SQL) API account. You need to create an Azure function that will access the database to retrieve records based on a variable named accountnumber. The solution must protect against SQL injection attacks. How should you define the command statement in the function?

Nội dung câu hỏi

You have a database in an Azure Cosmos DB Core (SQL) API account. You need to create an Azure function that will access the database to retrieve records based on a variable named accountnumber. The solution must protect against SQL injection attacks. How should you define the command statement in the function?

Các lựa chọn

Đáp án được giữ gọn theo nhãn A, B, C, D trong phần bình chọn tương tác.

  1. A. cmd = "SELECT * FROM Persons p WHERE p.accountnumber = 'accountnumber'"
  2. B. cmd = "SELECT * FROM Persons p WHERE p.accountnumber = LIKE @accountnumber"
  3. C. cmd = "SELECT * FROM Persons p WHERE p.accountnumber = @accountnumber" — đáp án hiện tại
  4. D. cmd = "SELECT * FROM Persons p WHERE p.accountnumber = '" + accountnumber + "'"

Cộng đồng

0 bình luận công khai. Tên thành viên được ẩn một phần.

Chưa có bình luận. Mở giao diện tương tác để bắt đầu thảo luận.

Câu hỏi liền kề