I want to get data on particular range of column in a table. but the data is of type varchar.

Suppose i have table student and a column is ID and the value in the ID is as AB12346854, and I need to find all the students in range of id AB12346854 to DE12548847 I tried using the query as 

```
select * from students where id>='AB12346854' and id<='DE12548847'.

```

I am getting rows with id value as null .( id is not primary key)