simlaudato / asterixdb

Automatically exported from code.google.com/p/asterixdb
0 stars 0 forks source link

NPE returned when using incomplete type #739

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
Reproduction:
==============
The code below works:
create type user_type as open{
id: uuid
}

create dataset tmp(user_type)
primary key id autogenerated;

However this one returns null[] on the result page and an NPE in the cc log:

create type user_type as open{
user: uuid //<== "id" missing to match the dataset PK use
}

create dataset tmp(user_type)
primary key id autogenerated;

Log: 
=====
SEVERE: null
java.lang.NullPointerException
edu.uci.ics.asterix.om.types.ARecordType.validatePartitioningExpressions(ARecord
Type.java:263)

Original issue reported on code.google.com by ker...@gmail.com on 19 Mar 2014 at 11:31

GoogleCodeExporter commented 8 years ago
Don't we need to give a semicolon after uuid, in the user_type definition ?

Is "uuid" a new datatype in the system ? Is it built-in/user defined ?

Original comment by khfaraaz82 on 20 Mar 2014 at 12:14

GoogleCodeExporter commented 8 years ago
Hi Khurram! 

Thanks for the feedback :)

The auto-generated feature is new (v8.3) and wasn't added to our documentation 
just yet. Adding a semi-column after uuid generates a syntax-error, as a curly 
bracket is required to close the type definition.

Cheers,
Keren

Original comment by ker...@gmail.com on 20 Mar 2014 at 6:36

GoogleCodeExporter commented 8 years ago
Already fixed in master

Original comment by ildar.absalyamov on 25 Oct 2014 at 11:30