Q:

How to rename columns in ORMLite?

How can we rename column name in ORMLite? 
I am trying to write that query SELECT id as _id from some_table
Android Cursor Adapter requires us to have column named _id and ORMLite requires us to have column named id. 
I am trying to write that query and return Cursor from this query.
Dao<NewsArticle, Long> newsArticleDao =
       ((SomeApp)mContext.getApplicationContext()).getDAOConnection().getDAO(
            NewsArticle.class);

QueryBuilder<NewsArticle, Long> query = newsArticleDao.queryBuilder().selectRaw(
      "`id` as `_id`");
PreparedQuery<NewsArticle> preparedQuery = query.prepare();

CloseableIterator<NewsArticle> iterator = newsArticleDao.iterator(preparedQuery);

AndroidDatabaseResults results =
        (AndroidDatabaseResults)iterator.getRawResults();
cursor = results.getRawCursor();

That's what I have so far but I am getting this error when I pass query to iterator.
java.sql.SQLException: Could not compile this SELECT_RAW statement since the caller is expecting a SELECT statement.  Check your QueryBuilder methods.

A:

I guess I have to answer my question.
I still couldn't figure out how to rename column but I found the solution to problem.
Android Custom Adapter requires column named_id that's true but ORMLite doesn't require the column name to be id, I was wrong about that. It wants you to mark a column as id.
In my model, I marked my id and now it works like a charm.
 @DatabaseField(id = true)
 private long _id;

