I\'m using a precompiled Azure Function that looks:
public static async Task Run(Stream inputBlob, Stream outputJson, Stream outputXml, CloudTable schedulerT
According to your description, I have tested this issue about binding to the table output, I could make it work as expected. Here is my code snippet, you could refer to it.
function.json
{
"bindings": [
{
"name": "inputBlob",
"type": "blobTrigger",
"direction": "in",
"path": "input/{name}",
"connection": "AzureStorageConnectionString"
},
{
"type": "table",
"name": "outTable",
"tableName": "UploadFile",
"connection": "AzureStorageConnectionString",
"direction": "out"
}
],
"disabled": false
}
ICollector#r "Microsoft.WindowsAzure.Storage"
using Microsoft.WindowsAzure.Storage.Table;
using Microsoft.WindowsAzure.Storage.Blob;
public static void Run(CloudBlockBlob inputBlob, ICollector outTable, TraceWriter log)
{
string blobUri=inputBlob.StorageUri.PrimaryUri.ToString();
log.Info($"C# Blob trigger function triggered, blob path: {blobUri}");
outTable.Add(new UploadFile()
{
PartitionKey = "Functions",
RowKey = Guid.NewGuid().ToString(),
Name = blobUri
});
}
public class UploadFile : TableEntity
{
public string Name { get; set; }
}
CloudTable#r "Microsoft.WindowsAzure.Storage"
using Microsoft.WindowsAzure.Storage.Table;
using Microsoft.WindowsAzure.Storage.Blob;
public static void Run(CloudBlockBlob inputBlob,CloudTable outTable, TraceWriter log)
{
string blobUri=inputBlob.StorageUri.PrimaryUri.ToString();
log.Info($"C# Blob trigger function triggered, blob path: {blobUri}");
outTable.Execute(TableOperation.Insert(new UploadFile()
{
PartitionKey = "Functions",
RowKey = Guid.NewGuid().ToString(),
Name = blobUri
}));
}
public class UploadFile : TableEntity
{
public string Name { get; set; }
}
Modify your code and click Save, if the compilation executes successfully, then when the function is triggered, you could see the following log and the record is added to Azure Table Storage.

For more details, you could refer to this official document about storage table binding for Azure function.