logo

More Thoughts on Embedding Views

Yesterday I was really hoping you guys would prove me a Doubting Thomas and tell me how great it is being able to embed views from other databases. However, as I suspected, it's not all it's cracked up to be and most of you advise steering clear.

In any real-world scenario the method is almost useless. It would only be practical to use them if you work on one server and make your design changes on live databases, with no templates.

Having thought about it I think I've come up with the perfect solution (it wasn't hard Lotus!).

Ok, so you can insert a view based on a formula (see screenshot to the right), which is great. Why then can't you specify the target database as part of this formula, as in the screenshot below.

Like a fool I actually tried a few combinations of Replica ID/View Name in the formula pane, in the vain hope that this might actually be a hidden feature. Maybe it is, but I couldn't get it to work.

Wouldn't it be great if it did!? In place of the Replica ID value in this formula we could reference a field. In this field we store either the file path to the database or the Replica ID. We can then be sure that, no matter which server we're on or whether it's the live database or template, we're looking at the right view.

Maybe I'm wrong but I can't see any reason why this couldn't work. Access permissions maybe? But then how does this come in to play with the embedding other views method as it stands?

Comments

    • avatar
    • Esther
    • Tue 27 Jul 2004 09:04

    Years ago, when I was first starting out, I managed to do this with plain HTML (using a URL as the formula.) I had no idea that it was a big deal, and didn't bother to save the database. I'm kicking myself now, because apparently it's kind of a holy grail...I've tried on and off for the last few years to figure out how I did it. I'll certainly post the solution if I ever find it again, but I have the feeling it was one of those situations where it only works because I was too dumb to know it shouldn't! :o)

    • avatar
    • Esther
    • Tue 27 Jul 2004 09:30

    OK, this is not the solution I originally came up with, but it works, and seems to be cross-browser with the versions I'm working with (Mozilla 1.6 and IE6 on a PC; Mozilla 1.4.1 on Mac OSX).

    Use an iFrame. Since no HTML is allowed here, I've posted the code I used at {Link}

    • avatar
    • Jerry Carter
    • Tue 27 Jul 2004 09:31

    Yeah, Jake - I would have though the same... SHOULD WORK. Maybe try the field names I mentioned in my post (linked to yesterdays post here).

    $Subforms and $Subform_RepIDs

    Seems these would be editable too - even redefinable based on logic, which opens some additional doors. :-)

    • avatar
    • Edwin
    • Wed 28 Jul 2004 03:07

    As always the lovely people that bring us Domino/Notes have given us something we can almost use the way we "designers/developers" want it to work.

    In order for this to work there should be somekind of 'make'-framework to deploy a set of databases. Within a ini-file you should then be able to create the related database links thus solving this linking problem.

    As it is it is a feature with a great potential if they can make it more flexible.

    ps. Wouldn't it be great if they would make it possible to specify the server where it should get the data from . . . . . .

    It is good to have dreams, it would be better if they occasionally would come true :-)

  1. In order to use Views from other databases, try to give Xalan (apache.org) a look. I am currently using a Java WebQueryOpen agent to perform an XSLT transform, and it works like a charm...

    Performance seems to be ok too.

    • avatar
    • laurens
    • Mon 2 Aug 2004 08:10

    Hi Jerry,

    I tried your suggestion by adding a subform with an embedded view as an Create > Resource > Insert Resource. The subform displayed, but the embedded view doesn't contain any information. On your website you describe that you actually managed to do this. How?

    Thank you in advance.

  2. I know it isn't as beautiful as it should be, but I drafted a real world conceptual solution a few months ago that more than one developer has used in commercial applications: {Link}

    • avatar
    • Dave
    • Wed 18 Aug 2004 02:08 PM

    Airplay,

    This sounds like a good solution, but how do you set the frame of databse A to a form that shows a single category, using a key from database A?

  3. Dave,

    via @environment (I told ya it was ugly :-) or URL (querystring parsing).

    More in my comment reply to you below the original article: {Link}

Your Comments

Name:
E-mail:
(optional)
Website:
(optional)
Comment:


About This Page

Written by Jake Howlett on Tue 27 Jul 2004

Share This Page

# ( ) '

Comments

The most recent comments added:

Skip to the comments or add your own.

You can subscribe to an individual RSS feed of comments on this entry.

Let's Get Social


About This Website

CodeStore is all about web development. Concentrating on Lotus Domino, ASP.NET, Flex, SharePoint and all things internet.

Your host is Jake Howlett who runs his own web development company called Rockall Design and is always on the lookout for new and interesting work to do.

You can find me on Twitter and on Linked In.

Read more about this site »

More Content