1
私はアンドロイドカレンダーデータベースにクエリを行い、特定の 'iCalGUID'のイベントを探しています。ここ android.database.sqlite.SQLiteExceptionのSqlエラー:認識されないトークン
は、私が使用しているクエリですfinal Cursor cursor = resolver.query(uri.getCalendarUri(),
null, "events.iCalGUID=" + uid, null, null);
現在のuidが0804eaa1-3472-43df-96c2-af73ae5c31ab
である。しかし、このクエリ
android.database.sqlite.SQLiteException: unrecognized token: "0804eaa1": ,
while compiling: SELECT originalEvent, visibility, rrule, hide_declined, reminder_type, hasAlarm,
description AS suggest_text_2, rdate, transparency, timezone, dtstart, _sync_time, hasAttendeeData,
commentsUri, description, reminder_duration, htmlUri, _sync_account, _sync_version, hasExtendedProperties,
last_update_time, eventLocation, dtend, allDay, organizer, sync_source, deleted, url, originalInstanceTime, alerts_vibrate, importance, selfAttendeeStatus, eventTimezone, ownerAccount, _sync_account_type, lastDate, guestsCanModify, guestsCanSeeGuests, exrule, selected, title, _id, _sync_id, alerts_ringtone, calendar_id, access_level, _sync_local_id, title AS suggest_text_1, originalAllDay, iCalGUID, _sync_dirty, duration, parentID, color,
guestsCanInviteOthers,
exdate, eventStatus FROM view_events WHERE (1)
AND (events.iCalGUID=0804eaa1-3472-43df-96c2-af73ae5c31ab)
を実行しながら、私は例外を取得しています
どのように私はアンドロイドでこれを行うことができます ありがとうございました。
感謝を。できます。あなたの助けをお願いします。今、私はエラー列dosen'tが存在しています。そこでevents.iCalGUIDをview_events.iCalGUIDに変更しました。それはイベント列iCalGUIDを照会する正しい方法ですか? – Zach
テーブルによって異なりますが、フォーマットは 'yourtablename.yourcolumname = ...'でなければなりません – Caner
私はアンドロイドのデフォルトカレンダーデータベースを使用しています – Zach