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
1=== modified file 'src/main/java/com/akiban/sql/types/DataTypeDescriptor.java'
2--- src/main/java/com/akiban/sql/types/DataTypeDescriptor.java 2013-01-14 23:14:02 +0000
3+++ src/main/java/com/akiban/sql/types/DataTypeDescriptor.java 2013-01-20 03:21:21 +0000
4@@ -1094,9 +1094,12 @@
5 }
6
7 public DataTypeDescriptor getUnsigned() throws StandardException {
8+
9 TypeId unsignedTypeId;
10 if (typeId == TypeId.SMALLINT_ID)
11 unsignedTypeId = TypeId.SMALLINT_UNSIGNED_ID;
12+ else if (typeId == TypeId.MEDIUMINT_ID)
13+ unsignedTypeId = TypeId.MEDIUMINT_UNSIGNED_ID;
14 else if (typeId == TypeId.INTEGER_ID)
15 unsignedTypeId = TypeId.INTEGER_UNSIGNED_ID;
16 else if (typeId == TypeId.TINYINT_ID)
17
18=== added file 'src/test/resources/com/akiban/sql/parser/create-table-medint-unsigned.expected'
19--- src/test/resources/com/akiban/sql/parser/create-table-medint-unsigned.expected 1970-01-01 00:00:00 +0000
20+++ src/test/resources/com/akiban/sql/parser/create-table-medint-unsigned.expected 2013-01-20 03:21:21 +0000
21@@ -0,0 +1,13 @@
22+com.akiban.sql.parser.CreateTableNode@354742ee
23+name: t
24+statementType: CREATE TABLE
25+lockGranularity: R
26+existenceCheck: NO_CONDITION
27+tableElementList:
28+ com.akiban.sql.parser.TableElementList@597b3295
29+
30+ [0]:
31+ com.akiban.sql.parser.ColumnDefinitionNode@27360218
32+ type: MEDIUMINT UNSIGNED
33+ name: c
34+ elementType: null
35\ No newline at end of file
36
37=== added file 'src/test/resources/com/akiban/sql/parser/create-table-medint-unsigned.sql'
38--- src/test/resources/com/akiban/sql/parser/create-table-medint-unsigned.sql 1970-01-01 00:00:00 +0000
39+++ src/test/resources/com/akiban/sql/parser/create-table-medint-unsigned.sql 2013-01-20 03:21:21 +0000
40@@ -0,0 +1,1 @@
41+CREATE TABLE t (c mediumint unsigned)
42\ No newline at end of file

Subscribers

People subscribed via source and target branches

to all changes: