locked
Adding data into multiple tables issue RRS feed

  • Question

  • I have a lightswitch app I am trying to create and am running into issues. The app has one table that should already have populated data and the the other is for transactional data. I am looking to make a screen that will show autocomplete boxes for that pre populated data and then they can add the transactional information. The prepopulated info is person and shift info and the transactional data is moves per hour, etc...

    I need both tables to update and save that persons information with all moves per hour,etc. Is this possible? 

    I have tried creating the screens but only get text box option for the Person table

     
    • Edited by Eric4381 Friday, June 26, 2015 5:59 PM
    Friday, June 26, 2015 5:49 PM

Answers

  • Hi,

    Are you referring to 'CraneOperator' property of business type 'Person'? That type is not the same as your custom entity type 'Person'. Note:

    "Visual Studio 2013 also introduces two new controls for the Person data type - Person Viewer and Person Picker. These controls are available in an HTML client of a SharePoint-enabled app."

    See "Using the Person Business Type" on the LightSwitch Team blog.

    Dave


    Dave Baker | AIDE for LightSwitch | Xpert360 blog | twitter : @xpert360 | Xpert360 website | Opinions are my own. For better forums, remember to mark posts as helpful/answer.

    • Proposed as answer by Xpert360 Monday, June 29, 2015 11:50 AM
    • Marked as answer by Angie Xu Monday, July 6, 2015 5:14 AM
    Monday, June 29, 2015 11:49 AM

All replies

  • Do you have foreign keys setup in your external database? Also do your tables have a rowversion column? Dave

    Dave Baker | AIDE for LightSwitch | Xpert360 blog | twitter : @xpert360 | Xpert360 website | Opinions are my own. For better forums, remember to mark posts as helpful/answer.

    Friday, June 26, 2015 7:25 PM
  • I have a one to many relationship between the two tables and have ID's set on each table if that's what you mean by rowversion? 

    Friday, June 26, 2015 7:45 PM
  • Hi,

    Are you referring to 'CraneOperator' property of business type 'Person'? That type is not the same as your custom entity type 'Person'. Note:

    "Visual Studio 2013 also introduces two new controls for the Person data type - Person Viewer and Person Picker. These controls are available in an HTML client of a SharePoint-enabled app."

    See "Using the Person Business Type" on the LightSwitch Team blog.

    Dave


    Dave Baker | AIDE for LightSwitch | Xpert360 blog | twitter : @xpert360 | Xpert360 website | Opinions are my own. For better forums, remember to mark posts as helpful/answer.

    • Proposed as answer by Xpert360 Monday, June 29, 2015 11:50 AM
    • Marked as answer by Angie Xu Monday, July 6, 2015 5:14 AM
    Monday, June 29, 2015 11:49 AM