How would i design the relationship between "question", "subquestion", and "answer"

Hi all. Consider the following scenario:
Scenario:
A Question has an Answer, but some Questions have Subquestions. For example:
1. Define the following terms: (Question)
a) Object (1 marks) (Subquestion)
An instance of a class. (Answer)
b) ...
2. Differentiate between a constructor and a destructor (2 marks)
(Question)
A constructor constructs while a destructor destroys.
(Answer)
Question:
I want to model Questions, Subquestion, and Answer as Entities with relationships/associations, preferably binary relationships as i feel ternary relationships will be problematic while programming. Any suggestion on how i would
go about this?
There is never infinite resources.
For the Question Entity, a question has the attributes "QuestionPhrase <String>", "Diagram<Binary>", and "Marks
<Decimal>".
For the SubQuestion Entity, a subquestion has the attributes "SubQuestionPhrase <String>", "Diagram<Binary>", and "Marks <Decimal>".
For the Answer Entity, an answer has attributes, "AnswerPhrase<String>", "Diagram <Binary>"

Yes. I am in .Net. I sure do hope i did not ask in the wrong forum. :-|
Hi KCWamuti,
If you need to design the relationship between Question table and Answer table in SQL Server, as Uri’s and Visakh’s posts, you can create the foreign key to establish relationship between tables, and use join in query to get your desired result. For more
information about JOIN in SQL Server, please review this article:
Different Types of SQL Joins.
However, if you need to model Questions, Subquestion, and Answer as Entities in .Net, then the issue regards data platform development. I suggest you post the question in the Data Platform Development forums at
http://social.msdn.microsoft.com/Forums/en-US/home?category=dataplatformdev . It is appropriate and more experts will assist you.
Thanks,
Lydia Zhang

Similar Messages

  • How to create the relationship between ESSBASE 11 and DM in OBIEE11

    Hi Experts,
    I have one requirement that there is one property table named 'Store Master' in DW,and it contains a lot of attribute, such as Open Date, Close Date, IS 24 Hour etc.
    But another data source is essbase and based on this source, I create all reports.
    In ESSBASE, it has one dimension and hierarchy Location, and it has four level, Country(L1),Region (L2),Province(L3),Store(L4)
    So I want to know how to create the relationship between Location (ESSBASE) and Store Master (DM).
    I try to create one relationship in physical layer between Gen4,Location and Store, then drag the open date and close date into Location Dimension in BMM,then Presentation Layer.
    When I drag column 'Open Date' ,'Gen4,Location ' and 'Sales' into reports, it will generate the following error message:
    State: HY000. Code: 10058. [NQODBC] [SQL_STATE: HY000] [nQSError: 10058] A general error has occurred. [nQSError: 43113] Message returned from OBIS. [nQSError: 43119] Query Failed: [nQSError: 14020] None of the fact tables are compatible with the query request Dim Region.Store Open Date. (HY000)
    However, when I remove the column 'Open Date'. it will be ok.
    So what I missing the steps? Please help me. Thanks.

    >
    '2. Now, pull the 'Store' column from relational DB onto the Gen5, Location column from Essbase. This action now creates, two logical sources for your 'Store' column.'
    If the length from different data source is not same,such as 1001(DM),L_1001(ESSBASE), can I drag the 'Store' column from relational DB onto the Gen5, Location column from Essbase?
    I think it does not work.Right?Hi,
    I am not sure if you are talking about the length(as in varchar(128)) of the member value being different in different sources, or the member itself is different in both the sources.
    I am still assuming, that you are referring to the members not same in both the sources.If it is, the whole concept of federation is based on conforming dimensions. So, it needs that the same dimension information is present in both the sources and then only, you know we can analyze the numbers based on this dimension. So, either the dimension being different in both sources, or the members not present in both the dimensions might lead to incorrect numbers.
    So I select Store Attributes in relation DB and Location in ESSBASE in physical layer, then create the physical join, such as right("Hour Sales"."H_Sales".""."H_Sales"."Gen6,Location",4) = "Authorization".""."EDW"."T_EDW_MDM_STORE"."US_CODE", then drag the OPEN_DATE and CLOSE_DATE in relation DB to Location in ESSBASE in BMM,finially drag them into presentation layer.We create physical layer relationships, to send over the same relation to the underlying database during querying. So, creating a physical relationship between essbase cube and relation database would not help here.
    When you set up this federation, BI Server sends individual queries to each source and maps the conforming dimension members internally.
    Hope I was clear, and this helps.
    Thank you,
    Dhar

  • How to create the relationship between ESSBASE 11 and DM  in OBIEE 11G?

    Hi Experts,
    I have one requirement that there is one property table named 'Store Master' in DW,and it contains a lot of attribute, such as Open Date, Close Date, IS 24 Hour etc.
    But another data source is essbase and based on this source, I create all reports.
    In ESSBASE, it has one dimension and hierarchy Location, and it has four level, Country(L1),Region (L2),Province(L3),Store(L4)
    So I want to know how to create the relationship between Location (ESSBASE) and Store Master (DM).
    I try to create one relationship in physical layer between Gen4,Location and Store, then drag the open date and close date into Location Dimension in BMM,then Presentation Layer.
    When I drag column 'Open Date' ,'Gen4,Location ' and 'Sales' into reports, it will generate the following error message:
    State: HY000. Code: 10058. [NQODBC] [SQL_STATE: HY000] [nQSError: 10058] A general error has occurred. [nQSError: 43113] Message returned from OBIS. [nQSError: 43119] Query Failed: [nQSError: 14020] None of the fact tables are compatible with the query request Dim Region.Store Open Date. (HY000)
    However, when I remove the column 'Open Date'. it will be ok
    So what I missing the steps? Please help me. Thanks.

    >
    '2. Now, pull the 'Store' column from relational DB onto the Gen5, Location column from Essbase. This action now creates, two logical sources for your 'Store' column.'
    If the length from different data source is not same,such as 1001(DM),L_1001(ESSBASE), can I drag the 'Store' column from relational DB onto the Gen5, Location column from Essbase?
    I think it does not work.Right?Hi,
    I am not sure if you are talking about the length(as in varchar(128)) of the member value being different in different sources, or the member itself is different in both the sources.
    I am still assuming, that you are referring to the members not same in both the sources.If it is, the whole concept of federation is based on conforming dimensions. So, it needs that the same dimension information is present in both the sources and then only, you know we can analyze the numbers based on this dimension. So, either the dimension being different in both sources, or the members not present in both the dimensions might lead to incorrect numbers.
    So I select Store Attributes in relation DB and Location in ESSBASE in physical layer, then create the physical join, such as right("Hour Sales"."H_Sales".""."H_Sales"."Gen6,Location",4) = "Authorization".""."EDW"."T_EDW_MDM_STORE"."US_CODE", then drag the OPEN_DATE and CLOSE_DATE in relation DB to Location in ESSBASE in BMM,finially drag them into presentation layer.We create physical layer relationships, to send over the same relation to the underlying database during querying. So, creating a physical relationship between essbase cube and relation database would not help here.
    When you set up this federation, BI Server sends individual queries to each source and maps the conforming dimension members internally.
    Hope I was clear, and this helps.
    Thank you,
    Dhar

  • Question the relationship between AR invoice and Outgoing payment

    Dear All,
    Does anyone the know the the relationship between AR invoice and Outgoing payment? because I would like to print the report in specific date range. For example, today is 02 July 2009. I want to print "AR invoice as at 31 Mar 2009", by using SQL. It seems like date back.
    From Samson

    Hi Samson,
                      Even i haven't done much r n d  bout this but what i came to know is that, there might be a scenario where you may want to make a payment to your customer. In this case we can use the Outgoing payment for the same. The system doesnt stop you from doin so. I have seen this in SAP B1 2005B, PL34.
    Regards,
    Joseph

  • The relationship between production order and purchase requistion After running MPS

    Dear Experts:
         I met a issue . My users want to know the relationship between production order and purchase requistion . In my company we create production order and  purchase req. by  running MRP. our operations are:
    1. T-CODE: MD41  create planned order .
    2. T-CODE: CO41 convert planned order to production order .
    3. T-CODE: MD15 convert planned order to purchase Requisition.
      but I can't  find the  relation of them. would you like to give me some advices? thank you very much.

    Hello
    On the standard MTS process there is no link between the requirement (STO) and the replenishment element (production order).
    See the below extraction from note 12955:
    There is no index that the system could use to determine which issue element (sales order, planning, reservation, dependent requirement, ...) is covered by a certain receipt element (purchase order, production order, purchase requisition, planned order, stock level ...).
    A production order, for example, can be created to cover several different requirements, even when you are using lot sizing procedure EX.
    You can use transaction MD09 or MD04to determine the pegged requirements, but they are calculated dynamically and there is not fixed link between requirement and receipt.
    BR
    Caetano

  • What is the relationship between CGI-Executables and cgi-bin?

    I am trying to get CGIs working locally on my Mac and am having difficulty understanding the relationship between CGI-Executables/ and cgi-bin/.
    I have activated CGI in my httpd.conf file, and have the following perl test script: /Library/WebServer/CGI-Executables/test.cgi file, and have the file permissions set appropriatly
    If I call the script from the actual url: http://127.0.0.1/CGI-Executables/test.cgi, it doesn't work. If I use: http://127.0.0.1/cgi-bin/test.cgi, it works fine.
    Why cgi-bin and not CGI-Executables? What is the relationship between /Library/WebServer/CGI-Executables/ and cgi-bin?
    And how do I get CGIs working in individual users' Sites/ file? Do all CGIs go in the /Library/WebServer/CGI-Executables/ directory, or can each users' Site/ directory have it's own cgi-bin?
    Ti Powerbook G4   Mac OS X (10.4.4)  

    Now I am having trouble getting CGI to work in the user directories. I have a perl script that works for 127.0.0.1/cgi-bin/test.cgi, but not for 127.0.0.1/~joe/cgi-bin/test.cgi.
    My apache error log says:
    [Tue Feb 14 08:14:23 2006] [error] [client 127.0.0.1] Options ExecCGI is off in this directory: /Users/joe/Sites/cgi-bin/first.cgi
    Permissions for Library/WebServer/CGI-Exectuables/test.cgi and /Users/joe/Sites/cgi-bin/ are 777.
    I think the problem is somewhere in my directory configs. Apache has so many, it's hard to know what's what.
    Here's the first directory directives in httpd.conf:
    # First, we configure the "default" to be a very restrictive set of
    # permissions.
    <Directory />
    Options FollowSymLinks
    AllowOverride Options
    </Directory>
    Farther down, there's this, which I added ExecCGI and index.cgi:
    # Control access to UserDir directories. The following is an example
    # for a site where these directories are restricted to read-only.
    <Directory /Users/*/Sites>
    AllowOverride FileInfo AuthConfig Limit
    Options MultiViews Indexes SymLinksIfOwnerMatch Includes ExecCGI
    DirectoryIndex index.html index.cgi
    <Limit GET POST OPTIONS PROPFIND>
    Order allow,deny
    Allow from all
    </Limit>
    <LimitExcept GET POST OPTIONS PROPFIND>
    Order deny,allow
    Deny from all
    </LimitExcept>
    </Directory>
    Then down at the bottom of the file is something I suspect was added automatically when the user account was created:
    Include /private/etc/httpd/users/*.conf
    <Directory "/Users/joe/Sites/">
    Options Indexes MultiViews Includes
    AllowOverride None
    Order allow,deny
    Allow from all
    </Directory>
    To further confuse things, there is another file /etc/httpd/user/joe.conf that has additional user-directory directives:
    <Directory "/Users/joe/Sites/">
    Options Indexes MultiViews
    AllowOverride None
    Order allow,deny
    Allow from all
    </Directory>
    Is there something in all these directory configurations that is preventing the user from accessing cgi-bin? Can I add directives to an .htaccess file in the user directory.
    Ti Powerbook G4   Mac OS X (10.4.4)  

  • In which table we can find the relationship between Role id and Task id

    Hi Experts,
    In which table we can find the relationship between Role id and Task id in Cprojects.
    Thanks
    Subhaskar

    Hi Subhaskar,
    Apart from DPR_ENTITY_LINK , you can also get it from table DPR_PART.
    Please go through the below link
    http://wiki.sdn.sap.com/wiki/display/PLM/cProjectstablesin+SAP
    I hope this will help you.
    Regards,
    Rahul

  • How can I change the space between a checkbox and text all at one time? I have a lot of checkboxes in my form.

    How can I change the space between a checkbox and text all at one time? I have a lot of checkboxes in my form.

    Okay, I haven't found a way to add an extra space using Find/replace, but you might be able to add some text wrap to the check boxes that will push the text away from them.
    Open Find/Replace and click the Object tab.
    Click the Specify attributes to find button to the right of the Find Object Format: field.
    Under Basic Attributes, choose Stroke and then the Black swatch (assuming the black swatch is applied to the strokes of your check boxes). If there are no other stand-alone objects in your form with a Black stroke, this should be all you need. (If there are Black strokes on your table cells, they will be ignored.)
    Click OK
    Click the Specify attributes to change button to the right of the Change Object Format: field.
    Under Basic Attributes, choose Text Wrap & Other > Text Wrap > Type: > Wrap around bounding box (2nd button from left)
    Under Offset, set a Right offset at the distance you'd like to add (I don't know what units you use, but the 3-5 points might work for your purposes...might take some trial-and-error to get it where you want)
    Click OK
    Click Change All

  • How can I synchronize the app between my iPad and iPhone?

    How can I synchronize the app between my iPad and iPhone?

    Hi,
    May i know which app in particular you are taking about.
    If that is Adobe Reader you need to sign-in in Adobe Id and password and that should be it.
    Regards,
    Ajlan Huda.

  • If unboxed how could you tell the difference between refurbished imac and new imac?

    If unboxed how could you tell the difference between refurbished imac and new imac?

    Besides all of that, you can purchase Apple Care which will extend your warranty to 3 years just like you can on a brand new iMac.
    If you're considering a "refurbished" iMac, buy it ONLY from Apple.  I believe it's your best bet.

  • What is the Relationship between Update Rule and Infopackage/Transfer Rules

    Hello Experts,
    can you help explain these scenarios to me:
    What is the relationship between update rules and infopackges?
    What is the relationship between transfer rules and infopackges?
    What is the relationship between update rules and transfer rules?

    Hello,
    Info-packages trigger the data load into BW system from the source system. An info-package is created for a specific data source and info source combination.
    1) When you trigger the info-package it sends an request to the source system to start the extraction process and this corresponds to the step "Data Request Received" in monitor under details tab. It is the first step.
    2) Then the selections specified in the info-package are transferred to the source system to select the requested data from BW system. Then it is sent back to BW system.
    3) Once it reach BW, it gets into the PSA and then it gets updated into the data target (depends on what settings are made in IP). No rules (Transfer rules / update rules) comes into picture when data is stored in PSA. Only the transfer structure is used to map the BW info-objects with the source system fields.
    4) After data is stored into PSA, the update into the data targets begins. First the transfer rules are applied -> data then flows through the communication structure -> update rules are applied and finally the records gets updated into the data target. 
    The extraction flow is: -
    Source System (DS) -> PSA -> Transfer Rules -> Communication Structure -> Update Rules -> Data target.
    Info-package actually triggers the whole data flow in BW system.
    Hope it gives you a clear picture.
    Thx,
    Soumya

  • How can you tell the difference between ipad 2 and ipad 3 ?

    I need to know how can you tell the defferance between the Ipad 2 and Ipad 3 by just looking at it ?

    Well it hard to tell if you don't have the two side by side and compair it to...

  • Question about the relationship between a project and Mobile Me album

    Hello esteemed members of the Aperture community
    I have a puzzling issue. I have published a project on MobileMe. My project is arranged somewhat chronologically, and I want MobileMe to follow this. However, the MobileMe album in Aperture does not synchronize with the project, and subsequently, the gallery on MobileMe does neither. How do I tell the MobileMe album in Aperture to synchronize itself with my project, and update changes as I edit the project, or am I just totally confused...always a possibility?
    Thanks in advance

    You sort of answered your own question in the title: Your Mobile Me gallery is an album. By design, changing the sort order of a project does not affect the sort order of related albums and vice versa. You'll have to make those changes in the album to have them reflected in the gallery.
    I know of no way to have an album synchronize with a project. (Note: if you make adjustments to images or delete images from a project, those changes will be reflected in the album, but the sort order will not.)
    DLS

  • How do I print the contrast between "filled" text and its surrounding "box"?

    Hi,
    Apologies in advance for any ambiguity or confusion . . .
    I am a self-taught Photoshop user who has come upon a problem to which I cannot find an answer, despite searching online for hours . . .
    When I design a project, it looks beautiful on screen . . . when I print it, however, it loses the definition between colors inside a font and the shape surrounding the font . . .
    To be more exact:
    I am working at 300 dpi . . .
    I create a rectangle and fill it with red.  I then write text inside of the rectangle and the font color is white.  Onscreen, it looks clear and well-defined.  When I print it, however, there is not clear definition between the font and its surrounding area . . . the colors seem to bleed into each other . . . I have tried using different paper (glossy, matte, etc.), have tried putting a narrow stroke around the text, etc., but nothing help to clearly define the difference between the text and its surrounding shape/color.
    It also does not matter the size of the font, although the larger the font, the easier it is to "see" the difference.  But a white font at 24 point looks no sharper than a white font at 8 pt.
    I am using an Epson XP-610 printer . . . it is a home deskjet and I mainly design for fun, but this "lack of sharpness" on the fonts is driving me crazy.  I would included a screenshot, but it would not help much, since the project looks beautiful and clear on the screen.
    The colors only seem "muddled" when  I print.  Any advice, or even a point in the direction of something I can read to help me understand what to do, would be helpful. . . . TIA!I

    Hullo Cheapster:
    I too am confident that this facility does not exist in relation to the underline function as such. Nor am I aware of a workaround that would let you access it straightforwardly for routine usage in body text. The underline facility, like the strikethrough, is provided because it is standard in some documentation which a wordprocessing might be expected to serve - but as such, it is provided in limited conventional formats. Otherwise, I agree, it is not ideal typography.
    However, for occasional use, there are two workarounds you might like to consider. One is to use the line drawing facility available through the insert menu (insert shape, choose line; then grab its handles to make it horizontal) or the same process initiated from the objects icon in the toolbar.
    Be aware, however, that the above could require further attention to your wrap options: you would need to deselect any wrap - but could still need to modify your line spacing options to avoid irregular line spacings with the rest of your text.
    Possibly simpler is to bear in mind that you can produce an underline without its text. To do this, select underline (Command / U) and type "non-breaking spaces" (option / space). This would allow you to place your underline on a separate line from your underlined text. You could do the same with the strikethrough function, which you access via the effects section in the font panel for closer spacing; or alter the line spacing where you need to do this.
    Either of the above would affect your surrounding text in a way that would make these methods unsuitable for incorporation into body text.
    However, if your interest in doing this relates to headlines or the like, one or other of these options might suit your purpose.
    Regards.

  • How can I reduce the width between search results and the preview fly-out?

    Hello, I am using a custom masterpage that reduces the overall width of page content but I am seeing an issue with my enterprise search site. The search results look fine but there is a large horizontal gap between the results and document preview window
    (when mousing over a word/excel/powerpoint result). This means that the preview fly-out is hardly visible unless the user scrolls horizontally to the right. Can someone tell me how to set a reduced width between the results web part and the preview window?
    Example:

    I think the issue is with the Callout orientation, have you customized the page and if so then you can customize the callout.
    check "beakOrientation" and you can set values like topBottom, leftRight as per your requirement.
    see here for more information -
    http://msdn.microsoft.com/en-us/library/office/dn135236(v=office.15).aspx
    Hope this helps!
    Ram - SharePoint Architect
    Blog - SharePointDeveloper.in
    Please vote or mark your question answered, if my reply helps you

Maybe you are looking for

  • I have an iPad 1st Generation and would like to use it when in Istanbul.  How do I do this and will it cost anything?

    I have an iPad 1st Generation Wi-Fi + 3G but my network is Verizon.  I would just like to use it when in Istanbul to check and send email to the US and to Skype.  Is this possible? Do I need to enable or disable anything to use it, or just turn it on

  • Sound bar in programs not adjusting volume.

    The issue: Sound/volume bars in ANY program will not adjust "permanently" - but only momentarily before it jumps back to a louder setting (seems to be the max set for the system volume).  What I have attempted: I recently purchased this unit (17-f020

  • How do you find an event in iMovie? I input a file today.  It has disappeared.

    Today, i input a new event form my Sony camcorder into the latest version of iMovie.  It is labeled 2014-1-11.  I then imput another event and labeed it 2014-1-10. The first file name disappeared.  After about 75% of the second file was inported, iMo

  • Javascript help for date.

    I am starting to create a website and would like to include the current date on my site. I searched around on the internet and came across this code but it doesn't seem to show up when I include it in the code of the webpage. <script type="text/javas

  • What's this 'Zoom' feature in Safari?

    I was wondering what exactly do you do with this 'Zoom' feature in Safari 3.1.1. When I hit 'Zoom' the window just resizes. But I don't think anything gets zoomed in. So, what's this feature for? How to get this thing working?