Please, have a look at your query:
SELECT TOP n *
FROM Table
WHERE [conditions]
ORDER BY RND([number col])
I see few issues:
1) If
n
is parameter, you need to define it (see below).
2)
Table
is
reserved word[
^]. I'd suggest to change the table name.
3)
[conditions]
- to be able to use conditions in
WHERE statement[
^], you should provide at least a column name and comparison operator
WHERE ColumnName <operator> [condition]
4)
RND([number col])
is not known for MS Access, because
Rnd[
^] does not accept any input parameter.
By The Way:
ORDER BY statement[
^] with parameters behaves like
WHERE
statement.
So...
If you want to get 10 random numbers, you need to write a query, as is described here:
How to create a random number in an SQL query on Microsoft Access?[
^]
Create a randon unique number field in a query[
^]