Change-Id: I4619dc4d136990b46abc521b5a632480d3ab508b
Signed-off-by: Minje Ahn <minje.ahn@samsung.com>
int ret = MEDIA_CONTENT_ERROR_NONE;
char *query_str = NULL;
- query_str = sqlite3_mprintf("INSERT INTO %q (tag_id, media_id) values (%d, '%q');", DB_TABLE_TAG_MAP, tag_id, media_id);
+ query_str = sqlite3_mprintf("INSERT OR IGNORE INTO %q (tag_id, media_id) values (%d, '%q');", DB_TABLE_TAG_MAP, tag_id, media_id);
ret = media_svc_append_query(query_str, _content_get_uid());
return _content_error_capi(ret);