Bugs item #2015135, was opened at 2008-07-10 17:01
Message generated for change (Comment added) made by sjoerd
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=482468&aid=2015135&group_id=56967
Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: PF/runtime
Group: Pathfinder "stable"
Status: Open
Resolution: None
Priority: 5
Private: No
Submitted By: Ying Zhang (yingying)
Assigned to: Ying Zhang (yingying)
Summary: PF: pf:mil() can't deal with nil values in MIL results
Initial Comment:
If the result of the MIL code passed to pf:mil() is a BAT, and it contains nil
values in its head, or tail, error will happen when translating the MIL result
into XML elements, in elem_constr():
xquery>pf:mil('var a := new(str,str); a.insert(str_nil, "abc"); return a;')
more><>
MAPI = mone...@localhost:50000
QUERY = pf:mil('var a := new(str,str); a.insert(str_nil, "abc"); return a;')
ERROR = !ERROR: mposjoin: all BATs in the tail of the third input BAT (ws_item)
must have a dense head.
!ERROR: CMDmposjoin: operation failed.
!ERROR: interpret_params: fetch(param 1): evaluation error.
xquery>pf:mil('var a := new(str,str); a.insert("abc", str_nil); return a;')
more><>
MAPI = mone...@localhost:50000
QUERY = pf:mil('var a := new(str,str); a.insert("abc", str_nil); return a;')
ERROR = !ERROR: mposjoin: missing matches. The result requires the same number
of tuples as the first two input arguments: 1 < 2.
!ERROR: CMDmposjoin: operation failed.
!ERROR: interpret_params: fetch(param 1): evaluation error.
----------------------------------------------------------------------
>Comment By: Sjoerd Mullender (sjoerd)
Date: 2009-08-06 13:34
Message:
Jennie, what is the status of this?
----------------------------------------------------------------------
Comment By: Ying Zhang (yingying)
Date: 2009-02-17 12:37
Message:
sorry, forgot to change the test name in "All" file, when merged those two
tests into one.
This is fixed now.
----------------------------------------------------------------------
Comment By: Stefan Manegold (stmane)
Date: 2009-02-15 21:51
Message:
There appears to be only ONE test
$ l pathfinder/tests/BugTracker/Tests/pfmil_and_nil_in_results*
-rw-r----- 1 manegold ins1 1272 2009-01-29 14:10
pathfinder/tests/BugTracker/Tests/pfmil_and_nil_in_results.SF-2015135.stable.err
-rw-r----- 1 manegold ins1 1889 2009-01-29 14:10
pathfinder/tests/BugTracker/Tests/pfmil_and_nil_in_results.SF-2015135.stable.out
-rw-r----- 1 manegold ins1 138 2009-01-29 14:10
pathfinder/tests/BugTracker/Tests/pfmil_and_nil_in_results.SF-2015135.xq
while the "All" file (and this bug report) list(s) TWO:
$ grep pfmil_and_nil_in_results pathfinder/tests/BugTracker/Tests/All
NOT_ALGEBRA?pfmil_and_nil_in_results_1.SF-2015135
NOT_ALGEBRA?pfmil_and_nil_in_results_2.SF-2015135
Please check and fix.
----------------------------------------------------------------------
Comment By: Stefan Manegold (stmane)
Date: 2008-10-15 15:10
Message:
Jennie,
the expected output of your tests shows NIL values in the result of
pf:mil() as empty strings, making them indistinguishable from "real" empty
strings.
What about omitting the respective "head"/"tail" attribute completely in
case its value is NIL?
That would not only make empty strings and NIL values distinguishable, but
also IMHO match the NIL semantics (no value) better...
BTW, the problem is indeed not caused by/in elem_constr() itself, but
xmltab2() and/or attr_constr() do not handle NIL values correctly and hence
feed elem_constr() with inconsistent/incorrect input ...
----------------------------------------------------------------------
Comment By: Ying Zhang (yingying)
Date: 2008-09-05 18:26
Message:
Logged In: YES
user_id=341633
Originator: YES
tests added in
pathfinder/tests/BugTracker/Tests/pfmil_and_nil_in_results_{1,2}.SF-2015135
----------------------------------------------------------------------
Comment By: Ying Zhang (yingying)
Date: 2008-09-05 18:25
Message:
Logged In: YES
user_id=341633
Originator: YES
Jan,
Thanks for looking at this. I assigned it to you because cvs said the code
was latestly checked in by
you, but it doesn't have to mean you are responsible for fixing it. I will
try to fix it myself.
Regards,
Jennie
----------------------------------------------------------------------
Comment By: Jan Rittinger (tsheyar)
Date: 2008-09-05 17:06
Message:
Logged In: YES
user_id=993208
Originator: NO
I'm definitely not responsible for pf:mil and elem_constr() is a
deprecated proc. If you in addition use elem_constr() incorrectly it of
course fails.
What you would need is to turn nil values in ws_mil() into real strings
instead of str(nil).
If you want to use pf:mil please fix it yourself.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=482468&aid=2015135&group_id=56967
------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now. http://p.sf.net/sfu/bobj-july
_______________________________________________
Monetdb-bugs mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/monetdb-bugs