Last active
January 9, 2020 15:19
-
-
Save mirontoli/95d9c9fe4bbd4aad27d936baa288a7d1 to your computer and use it in GitHub Desktop.
Code from my [blog post](https://chuvash.eu/2020/01/09/filtering-azure-table-data-directly-in-the-azure-function-binding/)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"bindings": [ | |
{ | |
"authLevel": "anonymous", | |
"type": "httpTrigger", | |
"direction": "in", | |
"name": "req", | |
"methods": ["options", "get"] | |
}, | |
{ | |
"type": "http", | |
"direction": "out", | |
"name": "res" | |
}, | |
{ | |
"type": "table", | |
"name": "inputTable", | |
"tableName": "metadata", | |
"connection": "AzureWebJobsStorage", | |
"direction": "in", | |
"filter": "(PartitionKey eq '{package}')" | |
} | |
] | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
module.exports = async function(context, req) { | |
context.res = { | |
body: context.bindings.inputTable | |
}; | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment