DBFlow icon indicating copy to clipboard operation
DBFlow copied to clipboard

Names alias

Open OptimistNot opened this issue 10 years ago • 1 comments

Congrats! You see this test? https://github.com/Raizlabs/DBFlow/blob/56f83f4abb0c1d082b8457c4af2d9c66a49a2594/dbflow/src/androidTest/java/com/raizlabs/android/dbflow/test/AQL.java

this is from my code. As you see i'm using interface Columns as a reference to column names, now in my queries i have a problem, all my queries and query builders using this as reference like this:

    public static AQL getAQLById(Long id) {
        return new Select()
                .from(AQL.class)
                .orderBy(false, AQL.Columns.AQL_TIMESTAMP)
                .where(Condition.column(AQL.Columns.AQL_ID).is(id))
                .querySingle();
    }

but can't be used anymore because of alias names... as you understand i can't rebuild my project because of conflicts to generate Table_table and i can't change like 50 queries to alias names... sooooo... what you suggest? i would appreciate support for strings. Thank you!

OptimistNot avatar Jan 07 '16 16:01 OptimistNot

Sorry, the whole point of generated Property is to remove the non type-safe queries you could come across. You pretty much need to change all of the queries anyways in 3.0+

agrosner avatar Jan 10 '16 02:01 agrosner