-1

mysqlデータベースにデータを挿入する必要がある場合は、以下のコードを使用していることを意味します。

PropertyInfo unameProp =new PropertyInfo();
unameProp.setName("userName");//Define the variable name in the web service method
unameProp.setValue(selectedItem);//Define value for fname variable
unameProp.setType(String.class);//Define the type of the variable
request.addProperty(unameProp);

ここでは、addpropertyが使用されています....Androidのmysqlデータベースのデータを更新するためのコードはどのように記述されていますか...助けてください...

4

1 に答える 1

0

Android は sqlite をサポートしています

Androidでのdb挿入にはコンテンツ値を使用する必要があります

    ContentValues values = new ContentValues();
     values.put("userName", selectedItem); 



     db.insert(yrtbl, null, values);
     db.close();
于 2012-08-24T07:37:26.677 に答える