Prerequisites
- The
RWS Connect Live JDBCconnection from the Live JDBC reference, with yourx-api-key x_db_passwordalways names a stored credential — for a passwordless public user, RWS stores an empty credential once (e.g.PUBLIC_NO_PASSWORD); email connect@rwsintegration.com
Step 1: A first unpaged query
Count Rfam’s RNA families:Step 2: Paginate with a cursor
Thefamily table’s 4,227 rows fit under the 5,000-row unpaged cap, but it makes a perfect paging exercise with verifiable totals. rfam_acc is the primary key — the unique key paging needs:
The first call carries no
x_cursor; each response’s next_cursor feeds the next call, until it comes back null. In the RWS Application, the cursor pagination config from the Live JDBC reference drives the loop for you.
Verified result on the live service: 4,227 rows in 5 pages of up to 1,000 — 4,227 distinct accessions, no duplicates, no gaps (offset mode returns the identical set). The updated column is a MySQL TIMESTAMP and arrives as an ISO string.
A trailing
-- comment at the end of x_sql is safe: the pagination wrapper puts its closing parenthesis on a new line, so the comment can’t swallow it. Verified with this exact query.The Ensembl variant
Ensembl’s public server answers the same way — only the URL and user change:
Note the URL names no database — pick one per query with fully qualified table names, or put the schema in the URL.
DECIMAL and DATE columns were verified to arrive as exact strings.
MySQL notes
- MySQL as old as 5.6 works — both public servers run it.
- Paginated queries run as a derived table with
LIMIT ... OFFSETor a keysetWHERE— any validSELECTwithout its ownORDER BYworks. - A non-default port travels in the URL (
:4497above), nothing else changes.
Next steps
Live JDBC guide
The full reference: directives, pagination, errors
MariaDB tutorial
The same flow against the UCSC Genome Browser — and the one TLS gotcha