0
votes

I have a table schema looks like below:(Hash key is same for all the records, distribution is not that important for this scenario)

Is it possible to query this table only by hashkey and using order by on the secondary index ?

I could'nt find any sample for asp.net sdk. There is one example but the latest SDK does'nt have "KeyConditions" parameter on QueryRequest class.

HashKey | RangeKey | SecondaryIndex
   "1"    DateTime   OrderNo(Numeric)
   "1"    DateTime   OrderNo(Numeric)
   "1"    DateTime   OrderNo(Numeric)
1

1 Answers

1
votes

Note: I haven't used LSI and I'm using AWS Java SDK and not .NET.

The indices act the same as range key in terms of querying.

You can use Query with a hash-key, give it an index-name and scan-index-forward

These features are available in QueryRequest for .NET