+ SECURE_LOGI("SQL data control, select to provider_id: %s, data_id: %s, col_count: %d, where: %s, order: %s, page_number: %d, per_page: %d", provider->provider_id, provider->data_id, column_count, where, order, page_number, count_per_page);
+
+ ret = pkgmgrinfo_appinfo_get_datacontrol_info(provider->provider_id, "Sql", &provider_appid, &access);
+ if (ret != PMINFO_R_OK)
+ {
+ LOGE("unable to get sql data control information: %d", ret);
+ return DATACONTROL_ERROR_IO_ERROR;
+ }
+ if (provider_appid)
+ free(provider_appid);
+
+ if (NULL != access && !strcmp(access, WRITE_ONLY)) {
+ LOGE("Provider has given [%s] permission only", access);
+ free(access);
+ return DATACONTROL_ERROR_PERMISSION_DENIED;
+ }
+ if (access)
+ free(access);
+