Another modeling and architecture question

Hello,
For some reason I still can't get my head around DocDB for more complicated relationships...
An extreme example in my app is a Practice Session. A session contains many attributes and could have multiple tasks, resources, songs, play-lists, and exercises. All of these items are modeled separately and can be added through their own forms.
Therefore lists of these items can be selected to add to a session but they also exist on their own.(to add to other types) I understand in a relational model how these multiple items can be added to a session. Relations through integer foreign keys
etc make sense there. In documents of JSON on the other hand I don't understand how to save these files and then correctly query them.
Lets say I have a practice session form that adds all these multiple items when submitted to a session 
document.
here is a model of a practice session:
public class PracticeSessions : Document
[Key]
[ScaffoldColumn(false)]
[JsonProperty(PropertyName = "id")]
public string objId { get; private set; } // session_ID (Primary key)
[JsonProperty(PropertyName = "name")]
[Required]
[Display(Name = "Name")]
public string Name { get; set; } // session_name
[MaxLength(500)]
[Display(Name = "Content")]
[AllowHtml]
[JsonProperty(PropertyName = "content")]
public string Content { get; set; } // session_content
[JsonProperty(PropertyName = "practiceResources")]
[Display(Name = "Resources")]
public List<PracticeResources> PracticeResources { get; set; }
[JsonProperty(PropertyName = "songLearnList")]
[Display(Name = "Song Learnlist")]
public SongPlaylists SongLearnList { get; set; }
[JsonProperty(PropertyName = "learnSongs")]
[Display(Name = "Learn Songs")]
public List<Songs> LearnSongs { get; set; }
[JsonProperty(PropertyName = "songPlayList")]
[Display(Name = "Song Playlist")]
public SongPlaylists SongPlayList { get; set; }
[JsonProperty(PropertyName = "playSongs")]
[Display(Name = "Play Songs")]
public List<Songs> PlaySongs { get; set; }
[JsonProperty(PropertyName = "studyTasks")]
[Display(Name = "Tasks")]
public List<StudyTasks> StudyTasks { get; set; }
[JsonProperty(PropertyName = "practiceGoals")]
[Display(Name = "Goals")]
public List<PracticeGoals> PracticeGoals { get; set; }
[JsonProperty(PropertyName = "exercise")]
[Display(Name = "Exercises")]
public List<IPM2014.DataAccess.Exercise> Exercise { get; set; }
[JsonProperty(PropertyName = "objectType")]
public string objectType { get { return "practiceSessions"; } }
[JsonProperty(PropertyName = "userId")]
public string UserId { get; set; } // UserID
public PracticeSessions()
PracticeResources = new List<PracticeResources>();
Exercise = new List<Exercise>();
PracticeGoals = new List<PracticeGoals>();
StudyTasks = new List<StudyTasks>();
PlaySongs = new List<Songs>();
LearnSongs = new List<Songs>();
Practice resource:
public class PracticeResources : Document
[Key]
[ScaffoldColumn(false)]
[JsonProperty(PropertyName = "id")]
public string objId { get; private set; } // resource_ID (Primary key)
[JsonProperty(PropertyName = "name")]
[Display(Name = "Name")]
public string Name { get; set; } // resource_name
[JsonProperty(PropertyName = "description")]
[MaxLength(200)]
[Display(Name = "Description")]
[AllowHtml]
public string Description { get; set; } // resource_description
[JsonProperty(PropertyName = "notes")]
[MaxLength(500)]
[Display(Name = "Notes")]
[AllowHtml]
public string Notes { get; set; } // resource_description
[JsonProperty(PropertyName = "type")]
[Display(Name = "Type")]
public string Type { get; set; } // resource_type
[JsonProperty(PropertyName = "link")]
// [DataType(DataType.Url)]
[Display(Name = "Link")]
public string Link { get; set; } // resource_link
[JsonProperty(PropertyName = "image")]
[Display(Name = "Image")]
public byte[] Image { get; set; }
[JsonProperty(PropertyName = "objectType")]
public string objectType { get { return "practiceResources"; } }
[ScaffoldColumn(false)]
[JsonProperty(PropertyName = "userId")]
public string UserId { get; set; } // UserId
If items are selected from say a checklist box (of practice resources) I could capture the "ID" of each resource into an array and send that to the controller. At that point though the type is a string not an object of the list type I am
adding. There is then a mismatch of types. How do I add the resource items to the session document? It won't work to just add the ID strings. Do I need to query back to the practice resource documents to get full objects to enter as a list? Even
if I do this and it may work I end up with the whole practice resource object inside the session document and if anything changes in the original it will be forever out of sync. Does it even make sense to try to do this in a doc database? I
really like the lack of a schema and other features of Doc DB but I don't want to try to go forward with something that isn't the right choice. Should I go back to using SQL Server and EF for 
this? Thats what I was using originally but was worried about schema changes and scale.
Sorry for this long winded question but I need to know if I should change my DB back end before going any further. Please let me know if you need more detail than this.
Thank You

hello and thanks for your reply, I probably will e-mail you so we can talk a little more about this. I think I am doing part of what you mention "A
common approach would be to store "type" and "id" as separate fields," I just call the type, objectType. I would like to use the composite Id's but I don't know what the best practice is to create them (not to mention other products,
but RavenDB takes care of that for you) This would also make the document names 100% more friendly when browsing them. What is the best way to manage these so they are unique? My biggest question though is still how to model and create these documents correctly.
I have added below example JSON that currently gets created.
[JsonProperty(PropertyName = "objectType")]
public string objectType { get { return "practiceResources"; } }
[JsonProperty(PropertyName = "objectType")]
public string objectType { get { return "practiceSessions"; } }
/* practice resource */
"id": "7d2f2eb4-7c02-4cd0-9ff9-af8d85b692be",
"name": "Guitar Pro 6",
"description": "Program to play and create tabs.",
"notes": null,
"type": "Software",
"link": "no url",
"image": null,
"objectType": "practiceResources",
"userId": "b1185d7f-0fcb-4c5c-96b9-d145409de3ed",
"_rid": "rOcQAL3OQQFMAAAAAAAAAA==",
"_self": "dbs/rOcQAA==/colls/rOcQAL3OQQE=/docs/rOcQAL3OQQFMAAAAAAAAAA==/",
"_ts": 1418690921,
"_etag": "\"00009e00-0000-0000-0000-548f81690000\"",
"_attachments": "attachments/"
/* practice session example */
"id": "a96e2ccd-1eb1-49fc-8d90-48827ae382c1",
"name": "Zep Runthrough",
"content": "Play through songlists for Zep Songs,to remember each.",
"practiceResources": [],
"songLearnList": null,
"learnSongs": [],
"songPlayList": {
"id": null,
"name": "Zeppelin Songs",
"description": "All the songs to know and play",
"songs": [
"id": null,
"name": "In the Light",
"description": null,
"artist": "Zep",
"style": null,
"notes": null,
"bpm": null,
"progress": null,
"songPortion": null,
"complexity": null,
"done": null,
"totalTimeHours": null,
"videoLink": null,
"scoreLink": null,
"instrumentUsed": null,
"guitarTuning": null,
"latestUpdate": null,
"repertoire": null,
"favorite": null,
"transcribe": null,
"priority": null,
"objectType": "songs",
"userId": null,
"_rid": null,
"_self": null,
"_ts": 0,
"_etag": null
"id": null,
"name": "Ten Years Gone",
"description": null,
"artist": "Zep",
"style": null,
"notes": null,
"bpm": null,
"progress": null,
"songPortion": null,
"complexity": null,
"done": null,
"totalTimeHours": null,
"videoLink": null,
"scoreLink": null,
"instrumentUsed": null,
"guitarTuning": null,
"latestUpdate": null,
"repertoire": null,
"favorite": null,
"transcribe": null,
"priority": null,
"objectType": "songs",
"userId": null,
"_rid": null,
"_self": null,
"_ts": 0,
"_etag": null
"objectType": "songPlayLists",
"userId": "b1185d7f-0fcb-4c5c-96b9-d145409de3ed",
"_rid": null,
"_self": null,
"_ts": 0,
"_etag": null
"playSongs": [],
"studyTasks": [],
"practiceGoals": [],
"exercise": [],
"objectType": "practiceSessions",
"userId": "b1185d7f-0fcb-4c5c-96b9-d145409de3ed",
"_rid": "rOcQAL3OQQExAAAAAAAAAA==",
"_self": "dbs/rOcQAA==/colls/rOcQAL3OQQE=/docs/rOcQAL3OQQExAAAAAAAAAA==/",
"_ts": 1418690921,
"_etag": "\"00008300-0000-0000-0000-548f81690000\"",
"_attachments": "attachments/"

Similar Messages

  • Scalability and Architecture Question

    I am currently working on an app that will generate a resume
    from a set of user defined input into several different formats
    from an XML file (MS Word, PDF, TXT, HR-XML, and HTML). We are
    thinking that we will write all the files once at publish time and
    then store them (not sure where yet). We are doing this because we
    will be hosting the online version of the resume as a CFM file with
    access to all the other formats of the resume from their online
    resume. We are assuming that there will be many more reads then
    their will be writes over the life of the resume. So we don't want
    to compile these each time a user requests one (that is a Word,
    PDF, HTML, or HR-XML version).
    The question I have now is should we store the files in the
    database or the webserver.
    I would think that it makes sense to store them on the
    webserver. But as this will need to be in a clustered environment
    then I will need to replicate these across the farm as each new
    user creates a resume. So does anyone know if the penalty for
    replicating these across the farm is higher then calling them from
    database. Assuming that the average file size is 50K and on average
    50 files will be called over the life of the resume. Thoughts?

    Originally posted by: fappel.innoopract.com
    Hi,
    RAP doesn't support session switch over at the moment, that's true. But
    it supports load-balancing by using multiple workers. But once a session
    is opened at one worker all requests of that session are dispatched to
    this worker.
    Ciao
    Frank
    -----Ursprüngliche Nachricht-----
    Von: Mike Wrighton [mailto:[email protected]]
    Bereitgestellt: Freitag, 22. August 2008 11:35
    Bereitgestellt in: eclipse.technology.rap
    Unterhaltung: Will RAP work in a load-balanced system?
    Betreff: Will RAP work in a load-balanced system?
    Hi,
    Some of my colleagues were reviewing scalability in our web architecture
    and the question was raised about RAP scalability, in particular the
    issue that since session data is stored in memory and not in a central
    database, RAP sessions would not survive a server switch-over by a load
    balancer. Hope that makes sense?
    I was just wondering if anyone had come across this issue before and
    found a decent solution? It may just be a case of configuring the load
    balancer properly.
    Thanks,
    Mike

  • Spam filtering solution for iPhone and a question.

    I've read a lot of posts about spam filtering for the iPhone and have yet another solution and a question. I use SpamSieve and I am not affiliated with them in any way. The nice thing about SpamSieve is that if it is the first rule in your Mail.app rule set any mail that follows has already been filtered. All you need to do then is create another rule that redirects email to what ever mail account you choose. Since my ISP allows multiple accounts, I will simply create an iPhone@myISP account.
    Now the question. Is it possible to write an applescript that will turn the redirect rule on or off so that I don't have to dig into the rules section of Mail to get this done?
    Thanks

    Is it possible to write an applescript that will turn the redirect rule on or off so that I don't have to dig into the rules section of Mail to get this done?
    not at present time

  • Basic jsp and servlet question (JSP Model 2)

    Hi
    I want to make an website where i use JSP Model 2 architecture. However I got a basic question
    1. I need to separate business logic from presentation with the use of jsp and servlets. Meaning I want no html code in the servlet. Can you give a simple example of how this can be done? If I map my implementation of httpServlet to a jsp page in web.xml and override doPost() and doGet(). The calls to the jsp page comes to the servlet as it should. I want to process some methods (calling sessionbeans or similar which in turn calls entitybeans) and then show the jsp page.
    How do I show the jsp page without mixing html in the servlet as I've done below:
    doGet(HttpServletRequest req, HttpServletResponse res)
    PrintWriter p = response.getWriter();
    p.print("<html><body>Hello world</body></html>"); //I dont want to do //this, I want to display the JSP site
    doPost(HttpServletRequest req, HttpServletResponse res)
    //doSomething
    }Message was edited by:
    CbbLe

    You should treat your servlet class much like a controller, where you can then use JSP as the view. The way you achieve this is to use the forward() method in RequestDispatcher.
    Say you've got a servlet class org.yoursite.controller.YourController:
    public void doGet(HttpServletRequest req, HttpServletResponse resp)
      throws ServletException, IOException {
      //Set some value for use in the JSP file associated wth me
      req.setAttribute("greeting", "Hello world!");
      //Done with our business logic, off we go to the JSP file
      ServletContext app = getServletContext();
        RequestDispatcher disp;
        disp = app.getRequestDispatcher("/some/jsp/file.jsp);
        disp.forward(req, resp);
    }Now in your JSP file:
    <h1>Example</h1>
    <div>
      I just want to say <%= request.getAttribute("greeting") %>
    </div>Going to that servlet now executes business logic and then points to the JSP file for the view. You can forward from servlet to servlet too if needs be. The string you pass to forward() is whatever would be in the URI of the request so any <servlet-mapping> configurations in web.xml are used ;)
    There is some pretty in-depth documentation on the J2EE blueprints website, namely service-to-worker and front-controller patterns. I dare say if you're looking for this sort of code you'll want to look at the composite view pattern too (also on blueprints).

  • Question about  Jco conenctions/Logical name of the model and metadata

    Is it common to use the same logical name of the model and metadata across different enviroments?
    For example,  MODEL_DATA_DEST, META_DATA_DEST is used for DEV, QAS and PRD? Because i seem to have some trouble using code built in DEV to another environment if the logical name of the model and metadata is different.
    Thanks in advance

    Hi,
    No for every environment the logical name of the model and metadata are different...
    for eg: some logical names, 
    WD_RFC_METADATA_DEST
    WD_MODELDATA_DEST
    USERINFO_WD_RFC_METADATA_DEST
    USERINFO_WD_MODELDATA_DEST
    About JCo Details,
    SAP JCo Functions,Architecture,Applications,Installation,Client & Server Programming :
    http://help.sap.com/saphelp_nw70/helpdata/en/6f/1bd5c6a85b11d6b28500508b5d5211/frameset.htm
    Creating Jco destination:
    http://help.sap.com/saphelp_nw70/helpdata/en/3a/3b1b40fcdd8f5ce10000000a155106/frameset.htm
    Maintaining Jco destination:
    http://help.sap.com/saphelp_nw70/helpdata/en/94/3c1b40fcdd8f5ce10000000a155106/frameset.htm
    The SAP JCo Repository :
    http://help.sap.com/saphelp_nw70/helpdata/en/01/43e13d82fcfb34e10000000a114084/frameset.htm
    Dynamic Jco creation Blogs:
    /people/anilkumar.vippagunta2/blog/2007/02/06/dynamic-jco-creation
    /people/gregor.wolf3/blog/2004/09/23/from-function-module-to-jco-application--part-1-of-3

  • I need to know all the questions below.  I had to restore my computer to original state and now even if I sign on it won't let me sync my ipad or iphone.  the message is that it is synced to another library and it could wipe out my data on the ipad.

    I need to know all the questions below.  I had to restore my computer to original state and now even if I sign on it won't let me sync my ipad or iphone.  the message is that it is synced to another library and it could wipe out my data on the ipad.  Am I understanding correctly? I am running Windows 7 but have never had any problems.  Thanks

    You need iTunes on the computer. There is no iTunes for your phone. See:
    Locked Out, Forgot Lock or Restrictions Passcode, or Need to Restore Your Device: Several Alternative Solutions
    1. iOS- Forgotten passcode or device disabled after entering wrong passcode
    2. iPhone, iPad, iPod touch: Wrong passcode results in red disabled screen
    3. Restoring iPod touch after forgotten passcode
    4. What to Do If You've Forgotten Your iPhone's Passcode
    5. iOS- Understanding passcodes
    6. iTunes 10 for Mac- Update and restore software on iPod, iPhone, or iPad
    Forgotten Restrictions Passcode Help
    You will need to restore your device as New to remove a Restrictions passcode. Go through the normal process to restore your device, but when you see the options to restore as New or from a backup, be sure to choose New.
    Also, see iTunes- Restoring iOS software.

  • Model diloge button click open another diloge and close of another diloge close all model diloges.

    When user clickes on link he gets model diloge with some fields,
    when clicked OK button all values will save and user should get another diloge, and on another diloge save form will close, and that should close all diloges.
    Or we can have like on click on OK button close save values current diloge and open another one. and Another one when clicked submite close it.
    how this can be achive.
    i tried
    string pageUrl = "/siteName/_layouts/Solutionname/form.aspx?isdlg=1&ID=" + newRequestID;
    string script = @"<script type='text/javascript'>window.frameElement.commitPopup();
    var modalDialog;
    function ShowForwardDialog() {
    var options = {
    url: '" + pageUrl + @"',
    tite: 'Time Title...',
    allowMaximize: false,
    showClose: true,
    width: 440,
    height: 120 };
    modalDialog = SP.UI.ModalDialog.showModalDialog(options);
    ExecuteOrDelayUntilScriptLoaded(ShowForwardDialog, 'sp.js');</script>";
    ClientScript.RegisterClientScriptBlock(this.GetType(), "OKScript", script);
    also tried without window.frameElement.commitPopup(); but nothing seem working.

    I used 1600Mhz Corsair Vengeance RAM. You can either get it in matched sets or in single modules.
    The default system RAM is made by Samsung and also runs at 1600Mhz.
    Thinkpad W530, i7-3720QM, 1920x1080 screen, 32GB RAM, dual SSDs (Samsung 830, Crucial M4 mSATA), Quadro K2000M, 9-cell battery, DVD burner, backlit keyboard, Bluetooth, Intel 6300 wireless card

  • HT5699 Im from another country and ive lost the answers to my security questions. Help required

    Hi
    Im from another country and ive lost the answers to my security questions. Help required
    Thanks

    You need to contact Apple, either as described in that article or by filling out and submitting this form.
    (90034)

  • Question on Creating table from another table and copying the partition str

    Dear All,
    I want to know whether is there any way where we can create a table using another table and have the partitions of the new table to be exactly like the used table.
    Like
    CREATE TABLE TEST AS SELECT * FROM TEMP;
    The table TEMP is having range and hash partitions.
    Is there any way when we use the above command, we get the table partitions of TEMP to be copied to the new table TEST.
    Appreciate your suggestions on this one.
    Thanks,
    Madhu K.

    may this answer your question...
    http://asktom.oracle.com/pls/asktom/f?p=100:11:0::::P11_QUESTION_ID:595568200346856483
    Ravi Kumar

  • I have another account and my ipad with this account and the password i forget it and the reset question i need help my ipad need active to open thank

    my password

    i have another account and my ipad with this account and the password i forget it and the reset question help me my ipad need active to open and i know my account name

  • I have an existing new belkin modem router which works fine with quite a few wired and wireless products in my house. My question is if i buy a time capsule can i put it in another room and wirelessly connect it to the belkin modem router, I would then ju

    I have an existing new belkin modem router which works fine with quiet a few wired and wireless products in my house. My question is if i buy a time capsule can i put it in another room and wirelessly connect it to the belkin modem router, I would then just like my macbook pro and (imac future purchase) to wirelessly back up to it???????????

    Your will need to perform a Factory Default Reset on the TIme Capsule to clear out the current network settings and then reconfigure it to "join" your wireless network using the AirPort Utility setup application.
    To perform the Factory Default Reset on the Time Capsule....
    Pull the power cord from the back of the device
    Wait a few moments
    Hold in the reset button on the back of the Time Capsule and keep holding it an additional 8-10 seconds while you simultaneously plug the power cord back in to the Time Capsule
    Release the reset button after the hold period and allow 25-30 seconds for the Time Capsule to restart to a slow, blinking amber light
    On your Mac.....
    Open Macintosh HD > Applications > Utilities > AirPort Utility
    Click Continue
    Follow the guided setup and choose the "join" option when it appears duriing the setup
    You will need to know the exact type of wireless security that the Belkin router is using to enter this information during the setup of the Belkin. Otherwise, the Time Capsule cannot join the network, and you will receive an error message after the configuration process.

  • Hello I told you before that my ipad stolen and i dont have icloud , now i pay another ipad and i'm surprise becouse i found my notes that in my stolen ipad in my new one but i don't find anything else no bookmarkets no photos .. My question how did this

    Hello
    I told you before that my ipad stolen and i dont have icloud , now i pay another ipad and i'm surprise becouse i found my notes that in my stolen ipad in my new one but i don't find anything else no bookmarkets no photos .. My question how did this happen ??

    Your documents were synched with iCloud when you logged in with your AppleID.   If you had a photostream before, you could access some photos using the stream.

  • My sons dad bought him and ipod and my niece used her itunes library to add music and videos on it. They live in another state and we have questions because we don't want him to lose all of the music or any of the apps.

    My son's dad bought him an ipod and my niece used her itune library to put music and videos on his ipod. The problem we are haveing is that she lives in another state and we are not sure how to manange his account without losing some of the songs and all of his apps. There are some songs that are on his ipod that are duplicates, there are some songs that he doesn't like or listen to, and there are some songs on there that I do NOT want him to listen to because of the language and the lyrics. He is 10 there are just some things I feel that he is too young to listen to.

    Welcome to the Apple Community.
    You can use different ID's for iTunes and iCloud.
    Just delete the account in settings > iCloud and create them their own account.
    if the children are minors, you wiil need to create and be responsible for each account yourself.

  • Comparing ABAP development process with Model Driven Architecture concept

    My Background
    I am a postgraduate student writing a Masters Degree Dissertation titled “An Investigation into how compatible ERP Development Process is with Model Driven Development Philosophy: A SAP R/3 Case Study”.
    The aim of this project is to compare ERP system development process with Model Driven Development (MDD) and to identify whether and how they can be used together. Model Driven Architecture (MDA) is Object Management Group’s (OMG) flavour of the MDD philosophy and is the paradigm that will be used here.
    I have chosen SAP R/3 as my case study in order to narrow the research and want to explore the development processes/cycle involved in using ABAP/4 to reconfigure/customize SAP R/3 system during implementation.
    An overview of the MDA concept according to OMG is given below. Following this, I’ve provided some questions that are open to discussions.
    Overview of the MDA Concept
    The Model Driven Architecture (MDA) is an approach to software systems development that separates the specification of system functionality from the specification of the implementation of the functionality on a specific technology platform. The MDA concept provides an open, vendor-neutral approach to system interoperability.
    A recent study by the Middleware Company summarizes MDA paradigm as a development process that makes use of the following steps:
    1.     Secure business requirements for an application.
    2.     Develop UML diagrams for the domain model, independent of any particular technology (J2EE, Microsoft .NET, CORBA, etc). This UML model represents the core business services and components. This UML model is called Platform Independent Model (PIM) because it is completely technology-independent and will be the same regardless of whether you decided to use J2EE or .NET. You develop this UML model using UML modelling capabilities of an MDA-specific modelling tool.
    3.     Build UML diagrams for the application, specific to a particular technology (J2EE, for example). This UML model will have design patterns. This UML model is called Platform Specific Model (PSM). You can build this manually, or you can generate much of it using an MDA tool and hand-tune only pieces of it that require customisation.
    4.     Finally, generate the application code using an MDA tool. That is to say, instead of writing the application by hand based on the UML model, you generate the majority of it from the UML diagrams.
    To develop an application using MDA, it is necessary to first build a PIM of the application, then transform this, using a standardised mapping into a PSM, and, finally, map the latter into the application code.
    A mapping is a set of rules and techniques used to modify one model in order to get another model. In MDA, mappings are used for transforming:
    1)     PIM to PIM. This transformation is used when models are enhanced, filtered or specialized during the development lifecycle without needing any platform dependent information. One of the most obvious mappings is the analysis to design models transformation. PIM to PIM mappings, are generally related to model refinement.
    2)     PIM to PSM. This transformation is used when the PIM is sufficiently refined to be projected to the execution infrastructure. The projection is based on the platform characteristics. Describing these characteristics should be done using UML description. Going from a logical component model to a commercial existing component model is a kind of PIM to PSM mapping.
    3)     PSM to PSM. This transformation is needed for component realization and deployment. PSM to PSM mapping are generally related to platform dependent model refinement.
    4)     PSM to PIM. This transformation is required for abstracting models of existing implementations in a particular technology into a platform-independent model. This procedure often resembles a “mining” process that is hard to be fully automated. It may be supported by tools, though. Ideally, the result of this mapping will match the corresponding PIM to PSM mapping.
    Questions/Discussions
    1.     What specific stages are involved in development using ABAP/4? (e.g., requirements gathering, analysis, design, coding, etc)
    2.     Do these stages fit into any traditional software development lifecycle? (e.g. waterfall model, v-model, etc)
    3.     Which of the stages in (1) above best describes the Platform Independent Model (PIM) of the MDA concept above?
    4.     Which of the stages in (1) above best describes the Platform Specific Model (PSM) of the MDA concept above?
    5.     How does the Accelerated SAP roadmap relate to the MDA concept above?
    6.     Assuming there’s a change in business requirements of a company that could lead to reconfiguring/customizing the R/3 system, how is this achieved? For instance, if a model has earlier been developed for that particular process, how does the change in the model affect coding/modification?
    7.     How is coding achieved with respect to the reconfiguration of the business models or reference models?
    8.     Are all coding manually done or are there tools in the ABAP Workbench that enable codes to be generated automatically from the models of the system?
    9.     How much time is spent in coding compared to developing business models like EPC models?

    I've also read about the SAP Composite Application Framework (CAF).
    But it seems that it's only for Java development....

  • Using model 1 Architecture for inserting row into DB...

    The question is on the design of a JSP using Model 1 architecture.
    I have a html form with 3 fields taking input from user. I have made a java bean with 3 instance varibales in the name of the field names and with getter() setter() methods too.
    I dont want to hardcode the database access in the JSP. How do i acheive modularity or make use of object orientation concepts in the JSP to open aconnection and save the record into a database.
    I dont want the conventional way of harcoding like registering DriverManager... Creating Statement opject and OPening Connection...... and with Statement object to call executeUpdate() method...
    These all should be encapsulated in class and methods so that my JSP looks simple......
    Java Gurus, How do i get going.........

    Untill now, I have motsly written java web applications merely showing information; there's no insert or update available. nevertheless, the design pattern MVC or Model-View-Controller can work just as good for display-only web apps as for the rest.
    You're right if you don't want to have the database connection inside your JSP's. So how do you have to deal with it. The letters MVC already tell a part of the story. You have 3 kinds of objects :
    - Model : the so-called Java Beans; these objects refer to the concepts known to the usezr of the web app, like Client, Product, Order, Orderline, Invoice, Payment
    - View : these are the JSP's
    - Controller : this is the heart of the web app; Java uses the servlets to be the controller.
    But there's another kind of object you will need, namely the DAO or Data Access Object. These objects define the contact with the database, contain the SQL-statements and make objects of the Model type.
    I'll give 2 examples. The first is the GeneralDao which you define just once. This GeneralDao contains the database driver you're using.
    /** Java class "GeneralDao.java" generated from Poseidon for UML.
    * Poseidon for UML is developed by Gentleware.
    * Generated with velocity template engine.
    package org.gertcuppens.dao;
    // import java.util.*;
    import java.util.ResourceBundle;
    import java.sql.*;
    /* import org.apache.log4j */
    import org.apache.log4j.Logger;
    public abstract class GeneralDao {
    // operations
    * de GeneralDao is de algemene klasse waar alle andere DAO's of Data Access
    * Objects van erven. Het is de bedoeling om in deze klasse ��nmaal de
    * getConnection te defini�ren
    * <p>
    * getConnection() connecteert met de databank afhankelijk van de JDBC-driver
    * die voorhanden is. Deze methode zorgt ervoor dat alle afgeleide DAO's van
    * dezelfde driver gebruik maken terwijl er toch maar op ��n plaats de naam
    * van de driver gedefinieerd is.
    * </p>
         protected Connection getConnection()
              throws java.sql.SQLException
         Connection dbconn = null;     
         ResourceBundle resBundle;
         Logger mopoLogger = Logger.getLogger("mopo.log");               
         mopoLogger.debug("start connectie databank " );      
              try
              Class.forName("com.mysql.jdbc.Driver").newInstance();
              resBundle = ResourceBundle.getBundle("gcoConfig");
              mopoLogger.debug("ophalen resourceBundle (gcoConfig) " );
              String dbConnectie = resBundle.getString("databaseconnection");
              mopoLogger.debug("lezen databaseconnection in resourceBundle " );
              //dbconn = DriverManager.getConnection("jdbc:mysql://localhost/gco");
              dbconn = DriverManager.getConnection(dbConnectie);
              mopoLogger.debug("maken connectie databank " );
              } catch (InstantiationException e)
                   System.out.println("GeneralDao - Fout bij getConnection - instantiation " );
                   mopoLogger.fatal("GeneralDao - Fout bij getConnection - instantiation " );
                   e.printStackTrace();
              } catch (IllegalAccessException e)
                   System.out.println("GeneralDao - Fout bij getConnection - illegal acces " );
                   mopoLogger.fatal("GeneralDao - Fout bij getConnection - illegal acces " );
                   e.printStackTrace();
              } catch (ClassNotFoundException e)
                   System.out.println("GeneralDao - Fout bij getConnection - class not found " );
                   mopoLogger.fatal("GeneralDao - Fout bij getConnection - class not found " );
                   e.printStackTrace();
              return dbconn;
    } // end GeneralDao
    Each object of the Model type should have a corresponding DAO. In my webapp I had 3 kinds of model objects, so I've defined 3 DAO's. All these DAO's are children of the GeneralDao. I'll give an example of this.
    package org.gertcuppens.dao;
    import java.sql.Connection;
    import java.sql.PreparedStatement;
    import java.sql.ResultSet;
    import java.sql.SQLException;
    import org.gertcuppens.general.Gebruiker;
    /* import org.apache.log4j */
    import org.apache.log4j.Logger;
    public class GebruikerDao extends GeneralDao {
    * Zoekt de gebruiker op aan de hand van de opgegeven naam en wachtwoord
    * @return Gebruiker
    * @param _naam
    * @param _wachtwoord
    public Gebruiker findGebruiker(String naam, String wachtwoord)
    throws SQLException
         Logger mopoLogger = Logger.getLogger("mopo.log");               
         mopoLogger.debug("start findGebruiker" );      
    StringBuffer zoekString = new StringBuffer();
    zoekString.append ("select * from gebruiker ");
    zoekString.append("where naam=? and wachtwoord=? ");
         Connection con = getConnection();
    PreparedStatement ps = con.prepareStatement(zoekString.toString());
    ps.setString(1,_naam);
    ps.setString(2,_wachtwoord);
    ResultSet rs = ps.executeQuery();
    if (rs.next() )
    Gebruiker gebruiker = new Gebruiker(rs);
    rs.close();
    ps.close();
    con.close();
    mopoLogger.debug("gebruiker gevonden " + gebruiker.getNaam());
    return gebruiker;      
    else {
                   ps.close();
                   con.close();
                   mopoLogger.debug("geen gebruiker gevonden");
                   return null;
    } // end findGebruiker
    } // end GebruikerDao
    Want to know more about this ? Just give me a sign.

Maybe you are looking for

  • DMS Document Type - Repository

    Hi Experts, Need a help. Is this possible to link DMS document type (created with help of DC20) with dedicated content repository (OAC0)? Regards Adam

  • Photoshop CS6 Crashing multiple times

    My config: Windows 7 Professional 64Bit Intel Core i7 -3820 CPU @3.6Ghz Ram 16GB Photoshop CS6 13.0.1.34 Photoshop crashing 5-7 times per day. This is the error: Faulting application name: Photoshop.exe, version: 13.0.1.34, time stamp: 0x5269b25c Fau

  • Why constructor do not have return type

    Why constructor do not have return type

  • Visible / hide the tabs in JTabbed pane

    Hello, I've a frame with a tree on the left and a TabbedPane a on the right. I've 3 tab in my TabbedPane. I would like to change the visible tab when i clic on a node in the tree. My code is public void valueChanged(TreeSelectionEvent event) TreePath

  • Trouble with Importing from Canon 6d

    Hi, When I try to import from my Canon 6D (RAW), it shows all the previews, but will only successfully import a handful of the photos. I get a dialog box saying that the files cannot be read. If I turn off the camera, then try again, it imports just