Bug 1221051 - Inconsistent results of RIGHT function for different datasources
Summary: Inconsistent results of RIGHT function for different datasources
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: JBoss Data Virtualization 6
Classification: JBoss
Component: Teiid
Version: 6.2.0
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ER3
: 6.2.0
Assignee: Van Halbert
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2015-05-13 08:45 UTC by Juraj Duráni
Modified: 2016-02-10 08:53 UTC (History)
1 user (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2016-02-10 08:53:23 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Issue Tracker TEIID-3474 0 Major Closed Inconsistent results of RIGHT function for different datasources 2015-09-15 21:51:48 UTC

Description Juraj Duráni 2015-05-13 08:45:26 UTC
The RIGHT function returns different results for different datasources. Some of those results are inconsistent with definition of the RIGHT(x,y) function.
=======
*Query: SELECT intkey, RIGHT(intkey, 1) FROM table ORDER BY intkey*
*Teradata, SQLServer, Sybase, Ingres, MySQL, Oracle (this result is OK):*
0	0
1	1
2	2
...
10	0
11	1
...
100	0
101	1
*Postgres:*
0	0
1	1
2	2
...
10	10
11	11
...
100	100
101	101
*DB2:*
0	" "
1	" "
2	" "
...
10	" "
11	" "
...
100	" "
101	" "
=====

Query:SELECT intkey, RIGHT(intkey, 2) FROM table ORDER BY intkey
*SQLServer, Sybase, Ingress, MySQL, Teradata (this result is OK):*
0	0
1	1
...
10	10
11	11
...
100	00
101	01
*Oracle:*
0	<null>
1	<null>
2	<null>
...
10	10
11	11
...
100	00
101	01
*Postgres:*
0	0
1	1
2	2
...
10	10
11	11
...
100	100
101	101
*DB2:*
0	"  "
1	"  "
2	"  "
...
10	"  "
11	"  "
...
100	"  "
101	"  "

Comment 1 JBoss JIRA Server 2015-05-13 14:16:19 UTC
Steven Hawkins <shawkins> updated the status of jira TEIID-3474 to Resolved

Comment 2 JBoss JIRA Server 2015-06-22 15:22:57 UTC
Steven Hawkins <shawkins> updated the status of jira TEIID-3474 to Closed


Note You need to log in before you can comment on or make changes to this bug.