Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

order by #7

Open
ourweb4 opened this issue Apr 21, 2016 · 1 comment
Open

order by #7

ourweb4 opened this issue Apr 21, 2016 · 1 comment

Comments

@ourweb4
Copy link

ourweb4 commented Apr 21, 2016

Is there a way to use a order by statement in a select statement.

@sahandnayebaziz
Copy link
Contributor

@ourweb4 even though there is no direct method for doing order by through this library, you could try:

let select_stmt = try con.prepare("SELECT * FROM test WHERE Id=? ORDER BY [whatever]")

// send query
let res = try select_stmt.query(12345)

//read all rows from the resultset
let rows = try res.readAllRows()

// print the rows
print(rows)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants