您可以使用Azure Mobile服務來存儲和提取數據,每個移動服務都帶有數據庫。您可以試用trial version以查看它是否符合您的要求。
按照下面的步驟,通過Visual Studio來Azure的移動服務添加到您的項目:
1.) Right click on project node and select Add --> Connected Services.
2.) Sign-in with your Azure account. Click on Create Service to create new mobile service.
3.) Select the newly created mobile service and click Ok.
4.) It will add service.js, which contains Azure mobile service object.
5.) You can use Azure mobile service object to perform CRUD operations like
var CordovaAppClient
document.addEventListener("deviceready", function() {
CordovaAppClient = new WindowsAzure.MobileServiceClient(
"https://Dummyapp.azure-mobile.net/",
"IsBLy-----ScCqDMuCCZqVlF------");
});
function ReadData()
{
var table = CordovaAppClient.getTable("Item");
var query = table.where({ complete: true });
query.read().then(function(items)
{
listItems = $.map(items, function (item) {
alert(item.text);
});
});
}
function InsertData()
{
var table = CordovaAppClient.getTable("Item");
var inputTest = $('#txtData').val();
table.insert({ text: inputTest, complete: false })
.then(addmessage);
}
感謝您的見解。將對此進行進一步調查。 – Sam
它是否具有類似OData的功能?或者如何定製我的SQL可以根據連接,包括等等。謝謝! – Sam
是的,它支持OData,你可以用Joins編寫自定義查詢,不確定包含。你可以找到更多的細節http://azure.microsoft.com/en-us/documentation/articles/sql-database-get-started/ –