I am using SQLRETRIEVE to get the data from a table in SQL 2000, the problem is the table gets to large and I am getting an error 14, out of string space. I see that you can specify a maximum number of rows that will be returned but that wont help me unless I can specify a starting row in my query so that I am able to access the entire data set including the rows that are not retrived beyond the max row value. I just need to have access to 14 rows at a time to display on a screen, I have scroll and page up and down buttons to display the rows either above or below the 14 rows currently displayed. Is there a way that I can query and return a specific range of rows from SQL? I have looked and I don't see a way to do this, or is there a tricky technique that I can use in VB to get around this?

Thanks.

Dim b() As Variant
Dim c() As Variant
id& = SQLOpen("DSN=?;UID=?;PWD=?",,2)
qry = SQLExecQuery(id&, Database)
i% = SQLBind(id&,b,1)
i% = SQLBind(id&,b,2)
i% = SQLBind(id&,b,5)
i% = SQLBind(id&,b,6)
i% = SQLBind(id&,b,7)
i% = SQLBind(id&,b,11)
i% = SQLBind(id&,b,12)
l& = SQLRetrieve(id&,c)