1. Check out our companion app, Forums for Android! Download from Google Play

ContentProvider count(*)

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

  1. Gabox01

    Gabox01 New Member
    Thread Starter
    5

    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...