File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -353,10 +353,7 @@ export default class IBMiContent {
353353 async getLibraryList ( libraries : string [ ] ) : Promise < IBMiObject [ ] > {
354354 let objects : IBMiObject [ ] ;
355355 if ( this . ibmi . enableSQL ) {
356- // Build VALUES clause from the libraries array
357- const valuesClause = libraries . map ( lib => `('${ lib . trim ( ) } ')` ) . join ( ',\n ' ) ;
358-
359- const statement = `
356+ const statement = /*sql*/ `
360357 SELECT
361358 os.OBJNAME AS NAME,
362359 os.OBJTYPE AS TYPE,
@@ -368,8 +365,9 @@ export default class IBMiContent {
368365 EXTRACT(EPOCH FROM (os.CHANGE_TIMESTAMP)) * 1000 AS CHANGED,
369366 os.OBJOWNER AS OWNER,
370367 os.OBJDEFINER AS CREATED_BY
371- FROM TABLE(VALUES
372- ${ valuesClause }
368+ FROM TABLE(
369+ -- Build VALUES clause from the libraries array
370+ VALUES ${ libraries . map ( lib => `'${ lib . trim ( ) } '` ) . join ( ',' ) }
373371 ) AS libs(ELEMENT),
374372 TABLE(QSYS2.OBJECT_STATISTICS(
375373 OBJECT_SCHEMA => 'QSYS',
You can’t perform that action at this time.
0 commit comments