Merge lp:~oontvoo/akiban-sql-parser/unsigned into lp:~akiban-technologies/akiban-sql-parser/trunk

Proposed by Vy Nguyen
Status: Merged
Approved by: Vy Nguyen
Approved revision: 288
Merged at revision: 285
Proposed branch: lp:~oontvoo/akiban-sql-parser/unsigned
Merge into: lp:~akiban-technologies/akiban-sql-parser/trunk
Diff against target: 42 lines (+17/-0)
3 files modified
src/main/java/com/akiban/sql/types/DataTypeDescriptor.java (+3/-0)
src/test/resources/com/akiban/sql/parser/create-table-medint-unsigned.expected (+13/-0)
src/test/resources/com/akiban/sql/parser/create-table-medint-unsigned.sql (+1/-0)
To merge this branch: bzr merge lp:~oontvoo/akiban-sql-parser/unsigned
Reviewer Review Type Date Requested Status
Akiban Technologies Pending
Review via email: mp+144008@code.launchpad.net

Description of the change

add unsigned mediumint.

This should've been part of lp:~oontvoo/akiban-parser/mediumint_parser, but for reason, the last revision got left out.

To post a comment you must log in.
Revision history for this message
Vy Nguyen (oontvoo) wrote :

Self-approve (ssince it's simple, and tested )

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
=== modified file 'src/main/java/com/akiban/sql/types/DataTypeDescriptor.java'
--- src/main/java/com/akiban/sql/types/DataTypeDescriptor.java 2013-01-14 23:14:02 +0000
+++ src/main/java/com/akiban/sql/types/DataTypeDescriptor.java 2013-01-20 03:21:21 +0000
@@ -1094,9 +1094,12 @@
1094 }1094 }
10951095
1096 public DataTypeDescriptor getUnsigned() throws StandardException {1096 public DataTypeDescriptor getUnsigned() throws StandardException {
1097
1097 TypeId unsignedTypeId;1098 TypeId unsignedTypeId;
1098 if (typeId == TypeId.SMALLINT_ID)1099 if (typeId == TypeId.SMALLINT_ID)
1099 unsignedTypeId = TypeId.SMALLINT_UNSIGNED_ID;1100 unsignedTypeId = TypeId.SMALLINT_UNSIGNED_ID;
1101 else if (typeId == TypeId.MEDIUMINT_ID)
1102 unsignedTypeId = TypeId.MEDIUMINT_UNSIGNED_ID;
1100 else if (typeId == TypeId.INTEGER_ID)1103 else if (typeId == TypeId.INTEGER_ID)
1101 unsignedTypeId = TypeId.INTEGER_UNSIGNED_ID;1104 unsignedTypeId = TypeId.INTEGER_UNSIGNED_ID;
1102 else if (typeId == TypeId.TINYINT_ID)1105 else if (typeId == TypeId.TINYINT_ID)
11031106
=== added file 'src/test/resources/com/akiban/sql/parser/create-table-medint-unsigned.expected'
--- src/test/resources/com/akiban/sql/parser/create-table-medint-unsigned.expected 1970-01-01 00:00:00 +0000
+++ src/test/resources/com/akiban/sql/parser/create-table-medint-unsigned.expected 2013-01-20 03:21:21 +0000
@@ -0,0 +1,13 @@
1com.akiban.sql.parser.CreateTableNode@354742ee
2name: t
3statementType: CREATE TABLE
4lockGranularity: R
5existenceCheck: NO_CONDITION
6tableElementList:
7 com.akiban.sql.parser.TableElementList@597b3295
8
9 [0]:
10 com.akiban.sql.parser.ColumnDefinitionNode@27360218
11 type: MEDIUMINT UNSIGNED
12 name: c
13 elementType: null
0\ No newline at end of file14\ No newline at end of file
115
=== added file 'src/test/resources/com/akiban/sql/parser/create-table-medint-unsigned.sql'
--- src/test/resources/com/akiban/sql/parser/create-table-medint-unsigned.sql 1970-01-01 00:00:00 +0000
+++ src/test/resources/com/akiban/sql/parser/create-table-medint-unsigned.sql 2013-01-20 03:21:21 +0000
@@ -0,0 +1,1 @@
1CREATE TABLE t (c mediumint unsigned)
0\ No newline at end of file2\ No newline at end of file

Subscribers

People subscribed via source and target branches

to all changes: