computed field - Populating Application Tables from SQL Tables in Visual Studio Lightswitch -


i've written separate plug-in application log users activity in our office using specific piece of software sql database. plugin logs when user opens application, computer information, hardware, files open, how long took open file etc. etc..

now i'm trying use visual studio lightswitch 2012 make dashboard view data , having problems.

first have number of computed fields want user able sort by. example in database dates stored @ utc times, user wants see local times. found tutorial describes creating separate field updates automatically existing field. yet not work me because table defined in sql serer not light-switch can not create new write-able fields in table through light-switch. nor wan make changes sql database.

so i'm wondering if there way create separate "applicationdata" tables in light-switch automatically populated/updated data in sql server when application starts. , able relate these tables sql tables sorting/searching.

is possible , if should put code? there appload or appstarting method somewhere correct place put initialization code?

the way personally is:

  1. attach sql database external data source (you let lightswitch create data model database).
  2. add custom ria service re-use data model created step 1 (we're using method can add equivalent of computed properties can searched/sorted by).

if you're not familiar creating ria services consumption lightswitch, article, how i: display chart built on aggregated data, show need know create one. don't put off fact article explains creating entity illustrate aggregating data display in chart, basic techniques want same, ignore part chart.

your computed properties ordinary string properties in ria service (because lightswitch search/sort string properties).

because you'll creating custom entity exactly properties want (whether exist in database or not), lightswitch treat computed properties other string property.


Comments

Popular posts from this blog

linux - Does gcc have any options to add version info in ELF binary file? -

android - send complex objects as post php java -

charts - What graph/dashboard product is facebook using in Dashboard: PUE & WUE -