Bug 116514 - yield function doesn't accept ref as 1st arg
Summary: yield function doesn't accept ref as 1st arg
Status: RESOLVED WORKSFORME
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
5.1.6.2 release
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: Calc-Function
  Show dependency treegraph
 
Reported: 2018-03-20 05:56 UTC by Larry
Modified: 2018-03-20 22:00 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:


Attachments
spreadsheet showing bug (31.06 KB, application/vnd.oasis.opendocument.spreadsheet)
2018-03-20 05:56 UTC, Larry
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Larry 2018-03-20 05:56:24 UTC
Created attachment 140732 [details]
spreadsheet showing bug

This cell(b18):

=YIELD("2000-01-01","2002-01-01",0.1,103.63,100,2)

returns 8%; however, this cell(b19):

=YIELD($C$19,"2002-01-01",0.1,103.63,100,2)

returns #VALUE! despite $C$19 containing:

“2000-01-01”

as result of formula:

=TEXT($B$10,$B$3)

The b19 result should be same as b18 result.
Comment 1 Julien Nabet 2018-03-20 14:25:08 UTC
On Win7 with LO 6.0.2, I could reproduce this.

Eike: thought you might be interested in this one.
Comment 2 Larry 2018-03-20 15:23:47 UTC
After changing the 1st arg to yield to directly reference the data cell,
it worked.  IOW:

=YIELD(B10,B11,B9,B15,100,B12,B2)

returned 8%.

I could have sworn I'd tried that before and got some error msg,
but maybe that was before I changed the format of the B10 and B11
cells to date or something.

Sorry for noise, but I would strongly suggest providing more
helpful error msg than #VALUE!.  It's very confusing when
a literal date value, "01/01/2000", works, but a reference
to the same value in a cell doesn't.
Comment 3 m_a_riosv 2018-03-20 22:00:17 UTC
The issue was having the format between quotation marks in B3 = “YYYY-MM-DD", gives a text date inside quotes C19= "2000-01-01" , what it's not a valid text to convert in date value.