Advertisement
Guest User

Untitled

a guest
Jun 16th, 2019
83
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.06 KB | None | 0 0
  1. public static void FieldDevicePollingStatusDispatch_Run ([TimerTrigger("%ScheduleDispatch%")]TimerInfo myTimer,
  2. [Queue("%DispatchQueueName%", Connection = "AVStorageAccessKey")] out string msg, //output binding
  3. ILogger log)
  4. {
  5. oConnect.Open();
  6. DataTable oDataTable = new DataTable();
  7. SqlCommand objCommand = new SqlCommand("CallProc", oConnect);
  8. objCommand.CommandType = CommandType.StoredProcedure;
  9. objCommand.Connection = oConnect;
  10.  
  11.  
  12. SqlDataAdapter oDataAdapter = new SqlDataAdapter(objCommand);
  13. oDataAdapter.Fill(oDataTable);
  14.  
  15.  
  16. msg = // Content from the table, need one column from table.
  17.  
  18. }
  19.  
  20. [StorageAccount("AzureWebJobsStorage")]
  21. public static class QueueFunctions
  22. {
  23. [FunctionName("QueueOutput")]
  24. [return: Queue("myqueue-items")]
  25. public static string QueueOutput([HttpTrigger] dynamic input, ILogger log)
  26. {
  27. log.LogInformation($"C# function processed: {input.Text}");
  28. return input.Text;
  29. }
  30. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement