Wrox Programmer Forums
Go Back   Wrox Programmer Forums > .NET > Other .NET > BOOK: Beginning Microsoft Visual Studio LightSwitch Development
|
BOOK: Beginning Microsoft Visual Studio LightSwitch Development
This is the forum to discuss the Wrox book Beginning Microsoft Visual Studio LightSwitch Development by István Novák; ISBN: 978-1-1180-2195-8
Welcome to the p2p.wrox.com Forums.

You are currently viewing the BOOK: Beginning Microsoft Visual Studio LightSwitch Development section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old January 26th, 2012, 03:56 PM
Registered User
 
Join Date: Oct 2004
Posts: 9
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via ICQ to gelias
Default Many-to-many relationship supported in LightSwitch?

Does LightSwitch somehow support a many to many relationship? I tried to select Many & Many in the multiplicity columns but the "Add New Relationship" dialog says "Many to many" relationships are not supported.
MIght there be a workaround of some sort? I'm simply trying to create a linking table - for example: between computer machines and software titles (less than 50 each), where each title is associated with several machines, and each machine associated with several titles. The end result is to display [1] a list-detail screen where each machine name, selected from a list of machines, displays a detail (list) of software installed: title name, version nr..., and [2] a list-detail screen where each software title, selected from a list of titles, displays a detail list of machines where the title is installed: machine name, fixed IP...
My first thought is to create a DB with such a relationship directly within SQL Server, then attach/connect to that existing, external DB -- but then will LightSwitch also barf at accepting that relationship for a LightSwitch created application?
Thanks.
 
Old January 27th, 2012, 06:41 PM
Registered User
 
Join Date: Oct 2004
Posts: 9
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via ICQ to gelias
Default Many-to-many relationship in LS - workaround.

I found a workaround - perhaps helpful for some of you - in a blog by Microsoft's Andy Kung @
http://blogs.msdn.com/b/lightswitch/archive/2010/12/16/how-to-create-a-many-to-many-relationship-andy-kung.aspx
Blog updated on 3/17/2011. Depending on your experience and perspective, the 'workaround' may strike you as a kludge or a clever solution; it takes a little more work. I think it's clever as I certainly enjoy the RAD provided by LS and don't mind a little extra work.

However, I think pg.203 of Mr. Novak's very good LS book is not entirely true. After Step 5, as reads: "...the Designers in the LightSwitch IDE provide you with everything you need to create and handle tables and relationships." Having read Chap 7, with a fine!! explanation of the most common relationships, you may be surprised to find that LS 1.0 doesn't support "many-to-many" relationships in the "Add New Relationship" dialog; the dialog simply says "not supported." Hopefully it will be supported in later releases of LS.





Similar Threads
Thread Thread Starter Forum Replies Last Post
ProfileCommon not Supported Chris_Alis BOOK: Professional ASP.NET 4 : in C# and VB 2 September 26th, 2011 02:15 PM
Unable to connect to Lightswitch server wcmadness BOOK: Beginning Microsoft Visual Studio LightSwitch Development 1 August 8th, 2011 07:58 PM
New LightSwitch book - reference code issue LEGS BOOK: Beginning Microsoft Visual Studio LightSwitch Development 1 July 31st, 2011 04:43 PM
Is this book still supported? JasonRawlins BOOK: ASP.NET AJAX Programmer's Reference : with ASP.NET 2.0 or ASP.NET 3.5 ISBN: 978-0-470-10998-4 1 April 1st, 2009 08:56 PM
multivalue paramaters are not supported diegoo BOOK: Professional SQL Server Reporting Services ISBN: 0-7645-6878-7 2 February 20th, 2005 02:30 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.