StrataFrame Forum
Back
Login
Login
Home
»
StrataFrame Application Framework - V1
»
Business Objects and Data Access (How do I?)
»
Can a sub-query be used to fill a BO?
Can a sub-query be used to fill a BO?
Post Reply
Like
0
Can a sub-query be used to fill a BO?
View
Flat Ascending
Flat Descending
Threaded
Options
Subscribe to topic
Print This Topic
RSS Feed
Goto Topics Forum
Author
Message
Greg McGuffey
Greg McGuffey
posted 18 Years Ago
ANSWER
Topic Details
Share Topic
Group: Forum Members
Posts: 2K,
Visits: 6.6K
Can I use a sub-query as one of the fields in a sql statement used to fill a BO? E.g. here is an example of the statement I'd like to use:
Select
ID
,(Select StatusName
From StatusLookupTable
Where StatusID = t.StatusID) As StatusName
,Title
From TitleTable As t
StatusName wouldn't be a property the BO knows about.
This is perfectly valid SQL (use it all the time), but when I tried to use this with a bo, it bombed, saying that it couldn't find a field named "(select StatusName...." in the BO. Can this be done? If not any work arounds?
Reply
Like
0
Reply
Greg McGuffey
Greg McGuffey
posted 18 Years Ago
ANSWER
Post Details
Share Post
Group: Forum Members
Posts: 2K,
Visits: 6.6K
I got it working. It wasn't a problem with my query and filling the BO, it was a problem loading that data into a list view. The problem was that when the column with the sub query was getting filled it was using the sub query to do the replacement, not the alias name. I changed the DisplayFieldNames on the PopulationListSettings of the ListView to use the alias and boom it worked!
Reply
Like
0
GO
Merge Selected
Merge into selected topic...
Merge into merge target...
Merge into a specific topic ID...
Open Merge
Threaded View
Threaded View
Can a sub-query be used to fill a BO?
Greg McGuffey
-
18 Years Ago
Hey Greg, The BO can execute any query that you can execute on the...
Trent L. Taylor
-
18 Years Ago
Good to hear. I always forget about db debugging :pinch: I'm sure...
Greg McGuffey
-
18 Years Ago
I got it working. It wasn't a problem with my query and filling the...
Greg McGuffey
-
18 Years Ago
Post Reply
Like
0
Similar Topics
Post Quoted Reply
Reading This Topic
Login
Login
Remember Me
Reset Password
Resend Validation Email
Login
Explore
Messages
Mentions
Search