Please be aware that the content in SAP SQL Anywhere Forum will be migrated to the SAP Community in June and this forum will be retired.

While in Interactive SQL, one can enable Sybase to return multiple results by setting the isql_show_multiple_result_sets, and supposedly with an ODBC connection such should work from C#/.NET (not tested yet by us), as we use an OLEDB connector, we have not been able to figure out how to make such work.

As far as I can see, there's a DBPROP that should be set Reflection of OleDBDataReader code

But I cannot seem to pull together something that works.

Has anybody succeeded with this in Sybase Anywhere 12 (ASA12)?

asked 08 Jun '12, 05:20

Eric%20Hofer's gravatar image

Eric Hofer
accept rate: 0%

edited 11 Jun '12, 12:40

Martin's gravatar image



Wouldn't OleDbDataReader::NextResult() do the trick?

It seems similar to SADataReader's NextResult() method - but that's just a guess...

(08 Jun '12, 05:40) Volker Barth
Replies hidden

NextResult will only return the next row of the result set, but not multiple result sets.

(11 Jun '12, 12:33) Martin

@Martin: "Used to process multiple results that can be generated by executing batch SQL statements."

(11 Jun '12, 13:58) Breck Carter

@Martin: I don' think so (but I haven't tested that) - reading the next row is what DbDataReader.Read() is for, whereas Eric askes for the next result set...

(11 Jun '12, 15:40) Volker Barth

@Breck, @Volker: You are right, I mixed it with the Read function...

(12 Jun '12, 03:12) Martin

...and now we are waiting on Eric's test results...

(12 Jun '12, 03:53) Volker Barth
showing 1 of 6 show all flat view

Use a DataAdpater and fill a DataSet (and hope that the implementation of the DataAdapter really obey to the documentation)

From MSDN: "When multiple result sets are added to the DataSet each result set is placed in a separate table"

permanent link

answered 11 Jun '12, 12:38

Martin's gravatar image

accept rate: 14%

The docs for OleDbDataReader::NextResult() say this: Used to process multiple results that can be generated by executing batch SQL statements.

(11 Jun '12, 13:59) Breck Carter
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here



Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text]( "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:


question asked: 08 Jun '12, 05:20

question was seen: 4,548 times

last updated: 12 Jun '12, 03:53