• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Devaka Cooray
  • Knute Snortum
  • Paul Clapham
  • Tim Cooke
Sheriffs:
  • Liutauras Vilda
  • Jeanne Boyarsky
  • Bear Bibeault
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Ron McLeod
  • Piet Souris
  • Frits Walraven
Bartenders:
  • Ganesh Patekar
  • Tim Holloway
  • salvin francis

my exam cloud mock 3, about unidirectional relationship  RSS feed

 
Ranch Hand
Posts: 1732
12
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator


...Quest cloning actually creates duplicate questions prior to assign to a test... The new relationship between Test and Question will be:

Each test can have one or more questions.
Quest need not reference a test.
Select the best design approach for this scenario?
a. There is no way to implement this requirement.

b. introduce new join table name Question_Test. This join table must have two foreign key columns. One foreign key column refers to table Question and other must refer to table Test. Use oneToMany bidirectional relationship to implement data access for this tables.

c. European client must use the same functionality without question cloning to avoid this issue.

d. Introduce new join table named Question_Test. This join table must have two foreign key columns. One foreign key column refers to table Question and other must refer to table Test. Use oneToMany unidirectional relationship Question and Question_Test and oneToMany unidirectional relationship between Question and Question_Test to implement data access for this tables.

Given answer is B.
The relationship refers unidirectional oneToMany relationship.
Entity Question does not reference a Test.
Entity Test reference a collection of Entity Question.
This join table must be have two foreign key columns to make unidirectional relationship between Question and Test.




I believe the answer should be D.
B mentions it is a bidirectional relationship. But in the explanation, it says "the relationship refers unidirectional oneToMany relationship".
So, I think B is not the answer.
 
Creator of Enthuware JWS+ V6
Posts: 3273
296
Android Chrome Eclipse IDE
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

B mentions it is a bidirectional relationship. But in the explanation, it says "the relationship refers unidirectional oneToMany relationship".  


That must be a mistake...

D is looks better but it talks about having two unidirectional OneToMany relationships???

Use oneToMany unidirectional relationship Question and Question_Test and oneToMany unidirectional relationship between Question and Question_Test

 
We can walk to school together. And we can both read this tiny ad:
how do I do my own kindle-like thing - without amazon
https://coderanch.com/t/711421/engineering/kindle-amazon
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!