Home / CSE MCQs / Django :: Discussion

Discussion :: Django

  1. What happens if MyObject.objects.get() is called with parameters that do not match an existing item in the database?
  2. A.
    The Http404 exception is raised
    B.
    The DatabaseError exception is raised
    C.
    The MyObject.DoesNotExist exception is raised
    D.
    The object is created and returned

    View Answer

    Workspace

    Answer : Option C

    Explanation :



Be The First To Comment