Relation based on view

Questions and answers regarding general SQL and backend databases

Relation based on view

Postby tizzo » Thu Oct 13, 2011 4:03 pm

I'm trying to create a relation between a table and (on the right side) a view.
It seems to me it's possible since Servoy lets me design such a kind of relation...
but I still get an empty foundset.
am I doing right or there's something wrong in the relation's design?

thx in advance
tizzo
 
Posts: 10
Joined: Tue Apr 19, 2011 5:35 pm

Re: Relation based on view

Postby mboegem » Thu Oct 13, 2011 4:54 pm

Did you mark the row-identifier(s) in Servoy? Without this Servoy doesn't know what to query...
User avatar
mboegem
 
Posts: 1752
Joined: Sun Oct 14, 2007 1:34 pm
Location: Amsterdam

Re: Relation based on view

Postby tizzo » Thu Oct 13, 2011 5:06 pm

yes I did.
i've tried many ways, simplifying to only one constant value field, making some simple calculation, etc...
but i still can't get it work
:(
tizzo
 
Posts: 10
Joined: Tue Apr 19, 2011 5:35 pm

Re: Relation based on view

Postby mboegem » Thu Oct 13, 2011 11:23 pm

Did you try to query this view directly through an SQL-admin tool?

Also be aware that the data in a view is always altered from outside Servoy. So: once a result is cached in Servoy, you won't see changes in this result unless you completely refresh the foundset from database. As Servoy is only aware of db-changed done through a Servoy-client.

Depending on the 'cost' of your view, this might be anot do ideal solution to show your data.
User avatar
mboegem
 
Posts: 1752
Joined: Sun Oct 14, 2007 1:34 pm
Location: Amsterdam

Re: Relation based on view

Postby tizzo » Thu Oct 27, 2011 5:25 pm

you were right. I've redone it all from a blank situation and now it's ok.
It was probably a type mistake or my vision is getting worse, i don't know :wink:
thx
tizzo
 
Posts: 10
Joined: Tue Apr 19, 2011 5:35 pm


Return to SQL Databases

Who is online

Users browsing this forum: No registered users and 25 guests

cron