Issue 103528 - SQL BITXOR behaves as BITOR
Summary: SQL BITXOR behaves as BITOR
Status: CLOSED FIXED
Alias: None
Product: Base
Classification: Application
Component: code (show other issues)
Version: OOo 3.1
Hardware: PC Windows XP
: P3 Trivial (vote)
Target Milestone: OOo 3.2
Assignee: marc.neumann
QA Contact: issues@dba
URL:
Keywords: new_implementation
Depends on:
Blocks:
 
Reported: 2009-07-14 04:31 UTC by kovacsbv
Modified: 2017-05-20 11:42 UTC (History)
4 users (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments
bug doc with example queris showing bitor, bitxor (26.63 KB, application/vnd.sun.xml.base)
2009-07-14 07:20 UTC, drewjensen.inbox
no flags Details
patch file (799 bytes, patch)
2009-07-16 07:38 UTC, drewjensen.inbox
no flags Details | Diff
the correct change (799 bytes, patch)
2009-07-16 07:56 UTC, drewjensen.inbox
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this issue.
Description kovacsbv 2009-07-14 04:31:39 UTC
To reproduce:  Open a database, open a table that has an ID column.  Make a
column called "BID".  Go to Tools-SQL and run:
update "Events" set BID = BITXOR(ID, 1)
This will behave as:
update "Events" set BID = BITOR(ID, 1)
(BITXOR behaves as BITOR)
Comment 1 drewjensen.inbox 2009-07-14 07:19:22 UTC
Confirmed w/ 3.0.1 and DEV310m_15

Attaching bug doc - see sample queries

Comment 2 drewjensen.inbox 2009-07-14 07:20:17 UTC
Created attachment 63534 [details]
bug doc with example queris showing bitor, bitxor
Comment 3 drewjensen.inbox 2009-07-14 07:21:11 UTC
assign to developer

set intitial target
Comment 4 drewjensen.inbox 2009-07-14 07:55:43 UTC
well, about time isn't it.
Comment 5 Frank Schönheit 2009-07-14 08:19:23 UTC
fs->atjensen: Did you intentionally assign this to yourself?
Comment 6 drewjensen.inbox 2009-07-14 11:37:29 UTC
Sure - Assuming that's allowed.

Ocke's on vacation - so

Looked over the source file and it seems to be a simple typo in the
libarary.java file
        ....
        functionMap.put("bitor", bitor);
        functionMap.put("bitxor", bitor);
        ....

Checked that there is actually a bitxor function in the file - there is and it
looks correct

 - I will go ahead and rebuiild a jar file here with what looks like a line
(character) fix 
        ....
        functionMap.put("bitor", bitor);
        functionMap.put("bitxor", bitxor);
        ....

and if all works, attach a diff file to the issue.

(don't worry I won't make a habit of this)
Comment 7 Frank Schönheit 2009-07-14 11:49:37 UTC
ah, great, no problem with this - thanks!
Comment 8 drewjensen.inbox 2009-07-16 07:37:23 UTC
Changing the one line does seem to fix this issue and not to break anything else.

Attached patch file. (probably not exactly the type of file you wanted - but
hopefully it is ok)
Comment 9 drewjensen.inbox 2009-07-16 07:38:14 UTC
Created attachment 63581 [details]
patch file
Comment 10 drewjensen.inbox 2009-07-16 07:45:36 UTC
ah, that's rather embaressing - seems that patch is backwards, isn't it...
Comment 11 drewjensen.inbox 2009-07-16 07:56:30 UTC
Created attachment 63584 [details]
the correct change
Comment 12 ocke.janssen 2009-08-17 13:59:29 UTC
Fixed in cws dba32f
Comment 13 ocke.janssen 2009-08-17 13:59:55 UTC
Adding cc
Comment 14 ocke.janssen 2009-08-17 14:00:49 UTC
set target.
Comment 15 ocke.janssen 2009-08-20 06:39:59 UTC
Please verify. Thanks.

Before the patch the result for bitor and bitxor was the same.
Comment 16 kovacsbv 2009-08-20 15:26:04 UTC
Thanks, guys.  Who verifies?  Where do I get the patched version?  Or do I just
wait for OOo3.2?
Comment 17 Frank Schönheit 2009-08-21 08:05:53 UTC
Our QA verifies the issue in the CWS where it was fixed
(http://wiki.services.openoffice.org/wiki/ChildWorkSpace). When the CWS gets
approved by QA, it will be integrated into master builds, so one of the upcoming
development milestones from http://download.openoffice.org/next/index.html will
contain the fix.
Comment 18 marc.neumann 2009-08-27 08:04:46 UTC
add keyword new_implementation
Comment 19 marc.neumann 2009-08-27 09:41:00 UTC
forget the last comment about the new implementation

verified in CWS dba32f

find more information about this CWS, like when it is available in the master
builds, in EIS, the Environment Information System:
http://eis.services.openoffice.org/EIS2/cws.ShowCWS?Path=DEV300%2Fdba32f
Comment 20 Andrea Pescetti 2013-07-06 06:48:46 UTC
For the record, the fix is now included in the fix for bug 121754.