DataView -> Joined Subview -> how to connect two lists, using LookupWithPicker (which displays name instead of ID) RRS feed

  • Question

  • I have three lists - Orders, Client and Orders_Client (which keeps relations - many to many).

    In Orders_Client, there are such fields: ConnectionName (string), ID, ClientID (Number), OrderID (LookupWithPicker, which keeps data in such Format "123;#Name")

    There is custom aspx with Data View, which displays all orders related to current Client (I get current ID from querystring paramter -> http://site/Lists/Orders_client/page.aspx?IdClient=123)

    DataView gets data from Linked source (joined Subview - Orders List and Orders_client List). The connection look like this:

    <xsl:variable name="Rows" select="../../../Orders/Rows/Row[@ID=$dvt_ParentRow/@OrderID]
    Ok, so where is the problem? :) The thing is, that when I create new connection (NewOrders_Client.aspx), in LookUpField I have to enter ID, instead of Order's Name.

    Obviously, I am able to change display name settings in LookUpWithPicer column(OrderID), from ID to Name. But in that case, DataView can't displays current's client's orders.

    1st case) [@ID=$dvt_ParentRow/@OrderID]-> 1=1 :), so DataView displays all orders properly | I have to enter new Orders_Client, by putting number (I want name)

    2nd case) [@ID=$dvt_ParentRow/@OrderID] -> 1=SomeOrder, so DataView doesn't show any result. | I create new Orders_Client, by putting name

    I know, that's quite confusing, if something is unclear, I may add some screeshots.

    Friday, May 6, 2011 1:51 PM

All replies

  • > if something is unclear, I may add some screeshots.

    If you add screenshots add only the URLs that point to the screenshots (located on an accessible by anonymous site).

    There are still people with slow lines; in hotel lobbies etc. who don't want to be forced to open images.


    SP 2010 "FAQ" (mainly useful links): http://wssv4faq.mindsharp.com/default.aspx
    WSS3/MOSS FAQ (FAQ and Links) http://wssv3faq.mindsharp.com/default.aspx
    Both also have links to extensive book lists and to (free) on-line chapters
    • Marked as answer by Leoyi Sun Monday, May 23, 2011 7:56 AM
    • Unmarked as answer by simon17 Monday, May 30, 2011 11:51 AM
    Friday, May 6, 2011 3:23 PM