Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

close(cR2021a - rows and database return

SQL = ['SELECT study.examno,study.series,study.name, projectgroupstudymri.type, ',...
'analysisfmritype.task,analysisfmritype.chaltype FROM study ',...
'INNER JOIN projectgroupstudymri ON projectgroupstudymri.study_id=study.study_id ',...
'INNER JOIN analysisfmritype ON analysisfmritype.analysisfmritype_id=projectgroupstudymri.analysisfmritype_id ',...
'WHERE projectgroupstudymri.projectgroupstudymri_id=',int2str(projectgroupstudymri_id)];

...

Code Block
languagematlab
c = exec(conn,SQL);
c=fetch(c);
if rows(c) > 0
  ...
end
close(c)

New

Code Block
languagematlab
Data = fetch(conn,SQL,'DataReturnFormat','cellarray');
if size(Data,1) > 0
    A.num_studies(i) = size(Data2,1);...
end