1. Download our Official Android App: Forums for Android!

Apps ContentProvider count(*)

Discussion in 'Android Development' started by Gabox01, Oct 9, 2010.

  1. Gabox01

    Gabox01 Lurker
    Thread Starter
    Rank:
    None
    Points:
    5
    Posts:
    1
    Joined:
    Oct 9, 2010

    Oct 9, 2010
    1
    0
    5
    Hi,

    Anybody knows how to query a ContentProvider in way to return only the row count?

    i want select count(*) from table

    How can i pass that to this method? :

    Code (Text):
    1.  public Cursor query(Uri uri, String[] projection, String selection, String[] selectionArgs,
    2.             String sortOrder) {
    Thanks,
    Gabox
     

    Advertisement

Share This Page

Loading...