简体   繁体   中英

Does the azure .net server sdk automatically handle queries from the .net client library event without the corresponding controller actions?

If I use a query like this from the client, List<TodoItem> items = await todoTable.Where(todoItem => todoItem.Complete == false).ToListAsync(); the azure .net client sdk translates it into the corresponding URI : GET /tables/todoitem?$filter=(complete+eq+false) HTTP/1.1. However, if my .net backend does not have an corresponding end-point to match this, will the .net server sdk still take care of translating it to the corresponding sql statement and return results ?

The examples I have seen in the documentation seem to have controller actions only for // GET tables/TodoItem and // GET tables/TodoItem/{id} , so I was wondering how all the other queries would get handled ?

so I was wondering how all the other queries would get handled?

We can get The HTTP Table Interfac e from the blog. There are some snippet from the blog.

There are six distinct endpoints that you can use that the SDK exposes to us.

Operation   Endpoint    Description
GET /tables/{tablename} QUERY: Read all or a subset of records from the table
GET /tables/{tablename}/{id}    READ: Read a specific ID within the table
POST    /tables/{tablename} INSERT: Inserts a new record into the table
POST    /tables/{tablename}/{id}    UNDELETE: Undeletes a previously deleted record
PATCH   /tables/{tablename} UPDATE: Updates the provided record with new data
DELETE  /tables/{tablename} DELETE: Deletes (or marks for deletion) the provided record

will the .net server sdk still take care of translating it to the corresponding sql statement and return results ?

GET /tables/{tablename}

With this request, we can send an OData v3 query that includes a subset of the OData v3 specification. Filters, Selects, Skip/Take (paging) and IncludeTotalCount are supported more detail info about URL Conventions (OData Version 3.0) please refer to the article .

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM