【发布时间】:2021-12-21 20:01:02
【问题描述】:
在我们的应用程序中,我们必须过滤一些数据。我们正在使用 Dynamo DB。在我们的团队中,我们对在发电机或应用程序级别使用过滤器表达式有不同的看法。我想知道这个行业一直在关注什么。如果您知道一些好的博客,请告诉我?
考虑这种情况,我们必须将交易模板置于活动状态,用户可以将其停用。在 get list 调用中,我们只想发送活动模板。
发电机:
filterCondition := expression.Name(activeColumn).Equal(expression.Value(true))
应用:
List<DealTemplate> templates = getTemplate()
for templaes := range templates {
if template.isActive {
// process
}
}
【问题讨论】:
标签: database nosql amazon-dynamodb