Calculated Field Using Fields from Subquery

Larry Beasley shared this question 7 years ago
Answered

I'm trying to use fewer views but in this situation, I am not able to. I have a large table for doctor visits that contains a field visit date. I have another table for patient's extra demographics with a date field. I want to calculate the datediff between these two dates. I surely can do this but not when the tables are joined in the report rather than the view. In this case, I will have to create another view simply for this report. We already have quite a few views and they are a headache to figure out what is what. Is this a limitation of the version we have?

Replies (3)

photo
1

Hi Larry,


Thanks for reaching out with your question. I've done some testing in Yellowfin 7.3 and found that as long as I created the Calculated Field in the Mastery Query, I was able to access fields from the Subquery. I did create a simple calculated field in this manner to take the difference between dates, but found that an Advanced Function was much more elegant in displaying the date difference. As you can see from my screenshot, I used the Advanced Function of "Days Between Date" to determine this difference.


9899b79a3112992acce178ba48e0b9ea87be36de02815f37ea19920eff6cdc6b


That being said, Yellowfin 7.1 has reached end of support and I highly advise you use our best practices for an upgrade and consider an upgrade path to 7.3.


Let me know if this helps you come to a resolution.


Thanks,

Ryan

photo
1

Thanks for that information. My organization has its license through Credible BH. That being said it sounds like we’re unfortunately stuck with an unsupported version of Yellowfin. Do you have version release notes? I’d like to share what we’re missing out on.

From: Yellowfin Support [mailto:support@yellowfin.bi]

Sent: Wednesday, April 19, 2017 5:54 PM

To: Larry Beasley

Subject: New Comment in "Calculated Field Using Fields from Subquery"

photo
1

Hi Larry,


As a clarification on 7.1 support, it's no longer receiving typical support releases but will still be updated for critical fixes through August of this year. You can visit the page here to see our release notes. There's a recorded webinar regarding our upcoming 7.3 + release here. This is slated for release in May. I'm sure with a little searching one could find previous videos highlighting key differences in our newer builds.


I also want to confirm that I did find I could use the previously mentioned method to calculate the difference between dates. Did this method help you achieve your results?


Thanks,

Ryan

photo
1

Yes but datediff was just part of a case statement so that I could use the data in a cross tab and column chart. My formula would generate '>= 1 Year', '< 1 Year' or 'Never' and I would count those instances. I just created another view. I really need to get someone to address the version update issue. There are a lot of features we are missing out on. Thanks!

photo
1

What about 7.2? Will this work on 7.2?

photo
1

Hi Larry,


On the subject of upgrading, you'll want to direct those inquiries towards your licenser, this case Credible. As I'm unsure as to the arrangements between yourself and the licenser, I'm unable to offer any guidance in those efforts at this time.


The method I've outlined will work in 7.2, however it sounds like it may require some additional steps to get it to accomplish your desired results. As far as the Calculated Field editor, with a Freehand calculated field, you can only access fields from the view of the report you are creating the field from. I understand this may not be the news you were hoping for and apologize for any inconvenience this may be causing.


Hopefully the method I offer gives some type of beneficial insight into a possible work around.


Thanks,

Ryan

photo
1

Hi Larry,


I'm going to go ahead and mark this as answered, as you have effectively achieved this result by creating a new view.


Thanks,

Ryan

photo
Leave a Comment
 
Attach a file