@awspilot/dynamodb

Issue Star Fork

2.0.2

support for delete attribute in transaction() update() and insert_or_update()
console.warn every time schema is not provided and a describeTable is called ( 3.x.x will throw err instead of calling describeTable )
moved testing from Travis to Github Actions
fix describeTable()
fix ProvisionedThroughput in sql 'DESCRIBE TABLE tbl_name' ( updated @awspilot/dynamodb-sql-util)
fix 'DESCRIBE TABLE tbl_name' when AWS does not return BillingModeSummary
updated (dev)dependencies

2.0.0

removed npm-shrinkwrap, was causing npm install to also install dev dependencies ( npm bug ?)
aws-sdk as peer dependency ( shrinks deply size for environments with embedded aws-sdk eg. Lambda )
experimental transactWrite support

1.5.1

import only dynamodb from aws-sdk

1.5.0

wrap around batchGetItem - .batch().table().get().get().read()
wrap around batchWriteItem - .batch().table().put().del().write()

1.4.0

.batch().table().put().put().del().write() - wrap around batchWriteItem
updated dev dependencies for security reasons

1.3.0

1.3.0+ will follow SemVer (major.minor.patch) and increment "minor" for new features
JSON keys in SQL can now be keywords without the need of wrapping: eg. { "keyword": 1 } can now be just { keyword: 1 }

1.2.11

SQL LIST and MAP support nested StringSet, NumberSet, BinarySet and Binary
SQL support insert/update BinarySet data type (BS) using Buffer.from( <STRING>, 'base64')
SQL support insert/update binary data type (B) using Buffer.from( <STRING>, 'base64')

1.2.10

SQL support for CREATE TABLE
pass an Array as parameter to select eg. .select(['attr1','attr2'])

1.2.9

SQL support for DROP TABLE
SQL support for DROP INDEX index_name ON tbl_name
updated SQL parser to support keywords in attribute names, table names and index names (eg: WHERE where = 5)

1.2.8

1.2.7

fixes a HUGE bug where float numbers may lose decimals in OOP .query(), SQL .query() do not have this bug

1.2.6

schema() : new method to supply primary key definitions for tables to avoid unnecesary describeTable calls

1.2.5

basic arithmetic operations can be used instead of String or Number, anywhere in SQL,
new function in SQL: uuid()
Eg.:
UPDATE tbl SET width = 100 + 20 WHERE `hash` = 'foo' + 'bar' AND `range` = ... ;
INSERT INTO tbl SET accountId = uuid('acct-############'), created_at = new Date().getTime()

1.2.4

@awspilot/dynamodb can now replace empty strings with custom values and convert back to empty strings when fetching data.

1.2.3

You can now use Javascript Math object in SQL queries as well as basic arithmetic operations as parameters for Date and Math Object
Eg.:
UPDATE tbl SET x = Math.round( Math.random() * 1000 ) WHERE ... ;
UPDATE tbl SET x = Math.round( new Date().getTime() / 1000 ) WHERE ... ;
UPDATE tbl SET x = new Date( new Date().getTime() - 1000*60*60*24 ).toISOString() WHERE ... ;

1.2.2

Support for SELECT without HAVING ( FilterExpression )
Eg.:
SELECT attr1, attr2 FROM tbl WHERE partition_key = 'value';
SELECT * FROM tbl WHERE partition_key = 'value' AND sort_key LIKE 'word%';
SELECT * FROM tbl WHERE partition_key = 'value' AND sort_key >= 5;
SELECT * FROM tbl WHERE partition_key = 'value' AND sort_key BETWEEN 'aaa' AND 'zzz';

1.2.1

Basic support for SCAN sql statement
Eg.:
SCAN attr1,attr2 FROM tbl

1.1.7

Support for javascript Date object in SQL queries
Eg.:
UPDATE tbl SET updated_at = new Date().getTime() WHERE ... ;