你好,请贴出查询代码。

InputStream in = null;
JSONObject jso = null;
String url = "https://api.leancloud.cn/1.1/classes/VideoSubFragment"
data = "{\"videoSubFragmentSourceObjectId\":" + videoSubFragmentSourceObjectId + "}";
jso = new JSONObject(data);
url = url + "?where=" + URLEncoder.encode(jso.toString(),"utf-8");

	 JSONObject jo = null;
	 JSONArray jsa = null;
	 HttpClient client = new HttpClient();
	 GetMethod getMethod = new GetMethod(url);
	 getMethod.addRequestHeader("Content-Type","application/json");
	 getMethod.setRequestHeader("X-LC-Id", OaConstant.appId);
	 getMethod.setRequestHeader("X-LC-Key", OaConstant.appKey);		  
	 client.getParams().setParameter(HttpMethodParams.HTTP_CONTENT_CHARSET, "utf-8");  		    
	//执行并返回状态
		try{
			status = client.executeMethod(getMethod);
			 //getUrl = getMethod.getResponseBodyAsString();
			in = getMethod.getResponseBodyAsStream();
			 BufferedReader br = new BufferedReader(new InputStreamReader(in));
				StringBuffer stringBuffer = new StringBuffer();  
				String str= "";  
				try {
					while((str = br.readLine()) != null){  
					stringBuffer.append(str );  
					}
				} catch (IOException e) {
					// TODO Auto-generated catch block
					e.printStackTrace();
				}  
			 getUrl = stringBuffer.toString();

		} catch (HttpException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		} catch (IOException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		} catch (JSONException e) {
			// TODO Auto-generated catch block
			e.printStackTrace();
		}

你所说的「有顺序的从1到10」,是指哪一个字段?我没有看到 VideoSubFragment 表里,有任何一个自增字段。

如果你查询的时候,不加任何条件,返回的数据是乱序的。我们一般,会以 createdAt 或者 updatedAt 字段的正序或者倒序的条件,来返回数据。

非常感谢,我手动添加了排序条件,因为之前在论坛中看到说默认是按照createdAt排序才有疑问的,总之非常感谢!!!