sails-dynamodb icon indicating copy to clipboard operation
sails-dynamodb copied to clipboard

Using dynamo mapped object type property attributes

Open tyronedougherty opened this issue 9 years ago • 4 comments

Hi, does anyone know how to use attributes that are Maps in DynamoDB with waterline?

The JSON type doesn't appear to work 😕

Many thanks to anyone who may be able to help!

tyronedougherty avatar May 04 '16 05:05 tyronedougherty

Correct me if I'm wrong but after much digging, it appears that JSON types are not supported?

Line 1126 of index.js (_setColumnType):

case "array":  // not support
          schema.StringSet(name, options);
          break;

             //case "json":
             //case "string":
             //case "binary":
        case "string":
             ....

Is there any chance of supporting JSON attributes in the near future?

tyronedougherty avatar May 05 '16 01:05 tyronedougherty

Definitely would take a PR!

devinivy avatar May 05 '16 03:05 devinivy

Thanks for clarifying @devinivy, in my quick assessment it seems like it may be a significant update and may require updating the vogels package (which is currently very out of date).

tyronedougherty avatar May 05 '16 04:05 tyronedougherty

Yeah, this module needs a makeover. Some day I'll have the time to do it, but for the time being I can just support by reviewing PRs.

devinivy avatar May 05 '16 11:05 devinivy