Why do i get {'No Data'} from large SQL query?

6 vues (au cours des 30 derniers jours)
Daniel Wesch
Daniel Wesch le 24 Août 2017
Commenté : Sailesh Sidhwani le 30 Août 2017
Hi,
I have a large SQL query string (6481 chars), which i have succesfully converted into a Matlab string. Sucessfully, since copying the string and inserting it into SQL Management Studio yields the correct table.
Now, retrieving the data through Matlab's database tools yields a 1x1 cell containing the string 'No Data'.
I've done hundreds of queries through the database tool, so I fail to see how this differs - the query is a bit more complicated than usual, but surely this should have no effect.
I'm aware it's a bit hard to troubleshoot, since it can't be reproduced, but please point me in the (a) right direction.
The server is running on Windows NT 6.3 (9600), 64 bits and the driver is ODBC.
With Microsoft SQL Server Enterprise V. 12.0.5000.0.
I'm using MATLAB R2016b.
Thanks!
  3 commentaires
Daniel Wesch
Daniel Wesch le 24 Août 2017
Yeah, I know, which is why I already flagged that. I had hoped that there might be some relatively known, generic problem.
In a nutshell, the problem is that the string works in SQL mgmt, but doesn't through the Matlab database tool.
Sailesh Sidhwani
Sailesh Sidhwani le 30 Août 2017
Hi Daniel,
If possible you can try switching to the JDBC driver and see if that resolves the issue. Also, following is link of common error with fetching data in MATLAB: https://www.mathworks.com/help/database/ug/fetching-data-common-errors.html

Connectez-vous pour commenter.

Réponses (0)

Produits

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by