Incorrect answer in Learn path, knowledge check

Iain Dobson 21 Reputation points
2023-12-01T16:58:41.31+00:00

Page: https://learn.microsoft.com/en-us/training/modules/implement-bicep/8-knowledge-check

Question 2.

Which of the following choices best describe the behavior of the webAppName parameter for a team that created a template that contains this line: param webAppName string = 'mySite${uniqueString(resourceGroup().id)}'?

  • Whoever is deploying the template must provide a value for the webAppName.
  • [Given Correct] When you redeploy the template to the same resource group, the value of the webAppName remains the same.
  • The webAppName parameter will have a different value every time the template gets deployed.

-> Above is incorrect.

Correct Answer:
The webAppName parameter will have a different value every time the template gets deployed.

Azure Training
Azure Training
Azure: A cloud computing platform and infrastructure for building, deploying and managing applications and services through a worldwide network of Microsoft-managed datacenters.Training: Instruction to develop new skills.
2,441 questions
0 comments No comments
{count} votes

Accepted answer
  1. Anonymous
    2023-12-02T07:02:43.2333333+00:00

    Hi Iain Dobson,

    Thank you for reaching out to us on the Microsoft Q&A forum.

    The option mentioned by you: The webAppName parameter will have a different value every time the template gets deployed as correct, is valid in case if we deploy a template with uniquestring() function to different resource groups or subscriptions.

    The second option given in knowledge check is right because “when you redeploy the template to the same resource group, the value of the webAppName remains the same is correct in this case because we are deploying the template to the same resource group”.

    The uniqueString() function is useful for creating globally unique resource names. It returns a string that's the same on every deployment to the same resource group, but it is different when you deploy to different resource groups or subscription.User's image

    We hope we have resolved your issue. Please don't hesitate to reach out to us if you have any other queries.

    Please Accept the answer if you have found this helpful so that it is helpful for others in the community.


0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.