Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
P
Postgres FD Implementation
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Abuhujair Javed
Postgres FD Implementation
Commits
8cb4e4f6
Commit
8cb4e4f6
authored
Dec 05, 2005
by
Tom Lane
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add regression test to see if the min/max values of int8 convert correctly.
parent
3311c766
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
40 additions
and
0 deletions
+40
-0
src/test/regress/expected/int8-exp-three-digits.out
src/test/regress/expected/int8-exp-three-digits.out
+17
-0
src/test/regress/expected/int8.out
src/test/regress/expected/int8.out
+17
-0
src/test/regress/sql/int8.sql
src/test/regress/sql/int8.sql
+6
-0
No files found.
src/test/regress/expected/int8-exp-three-digits.out
View file @
8cb4e4f6
...
...
@@ -300,3 +300,20 @@ SELECT '' AS to_char_17, to_char(q2, '999999SG9999999999') FROM INT8_TBL;
| 456789-0123456789
(5 rows)
-- check min/max values
select '-9223372036854775808'::int8;
int8
----------------------
-9223372036854775808
(1 row)
select '-9223372036854775809'::int8;
ERROR: value "-9223372036854775809" is out of range for type bigint
select '9223372036854775807'::int8;
int8
---------------------
9223372036854775807
(1 row)
select '9223372036854775808'::int8;
ERROR: value "9223372036854775808" is out of range for type bigint
src/test/regress/expected/int8.out
View file @
8cb4e4f6
...
...
@@ -300,3 +300,20 @@ SELECT '' AS to_char_17, to_char(q2, '999999SG9999999999') FROM INT8_TBL;
| 456789-0123456789
(5 rows)
-- check min/max values
select '-9223372036854775808'::int8;
int8
----------------------
-9223372036854775808
(1 row)
select '-9223372036854775809'::int8;
ERROR: value "-9223372036854775809" is out of range for type bigint
select '9223372036854775807'::int8;
int8
---------------------
9223372036854775807
(1 row)
select '9223372036854775808'::int8;
ERROR: value "9223372036854775808" is out of range for type bigint
src/test/regress/sql/int8.sql
View file @
8cb4e4f6
...
...
@@ -63,3 +63,9 @@ SELECT '' AS to_char_14, to_char(q2, 'FM9999999999999999.999') FROM INT8_TBL;
SELECT
''
AS
to_char_15
,
to_char
(
q2
,
'S 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 9 . 9 9 9'
)
FROM
INT8_TBL
;
SELECT
''
AS
to_char_16
,
to_char
(
q2
,
E
'99999 "text" 9999 "9999" 999 "
\\
"text between quote marks
\\
"" 9999'
)
FROM
INT8_TBL
;
SELECT
''
AS
to_char_17
,
to_char
(
q2
,
'999999SG9999999999'
)
FROM
INT8_TBL
;
-- check min/max values
select
'-9223372036854775808'
::
int8
;
select
'-9223372036854775809'
::
int8
;
select
'9223372036854775807'
::
int8
;
select
'9223372036854775808'
::
int8
;
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment