SAP-archive / com.sap.openSAP.hana5.example

openSAP HANA5/HANA6 Course: Example Completed Implementation
https://open.sap.com/courses/hana5/
Apache License 2.0
87 stars 81 forks source link

Error: "db://gm2t" is required but not provided by any file #1

Closed gregmisiorek closed 7 years ago

gregmisiorek commented 7 years ago

Hi Thomas,

great class, but i'm still struggling with exposing any data in views.

the full error console error dump:

12:17:03 PM (Builder) Build of /gm2p/gm2m started. 12:17:05 PM (DIBuild) Build of /gm2p/gm2m in progress 12:17:12 PM (DIBuild) ** Printing /gm2p/gm2m Build Log ** [INFO] Injecting source code into builder... [INFO] Source code injection finished [INFO] ------------------------------------------------------------------------ sap-hdi-deploy@2.0.0 node_modules/sap-hdi-deploy ├── async@1.4.2 ├── sap-xsenv@1.2.2 (debug@2.2.0, verror@1.6.0) └── hdb@0.5.3

deploy@ start /hana/shared/HXE/xs/ea_data/vhcalhxedb/executionroot/194a7474-491c-4f94-948c-f4c3103f7ce5/app/tomcat/temp/builder/hdi-builder/builds/build-4577747085478011748/gm2m node node_modules/sap-hdi-deploy/deploy.js

sap-hdi-deploy, version 2.0.0 Collecting files... Collecting files... ok (0s 2ms) Processing grants files... Processing grants files... ok (0s 0ms) Preprocessing files... Preprocessing files... ok (0s 2ms) Synchronizing files with the container "7QZP9UHWGMOQPQBN_GM2P_HDI_CONTAINER"... 4 modified or added files are scheduled for deploy 0 deleted files are scheduled for undeploy Synchronizing files with the container "7QZP9UHWGMOQPQBN_GM2P_HDI_CONTAINER"... ok (0s 983ms) Deploying to the container "7QZP9UHWGMOQPQBN_GM2P_HDI_CONTAINER"... Starting make in the container "7QZP9UHWGMOQPQBN_GM2P_HDI_CONTAINER" with 4 files to deploy, 0 files to undeploy... Migrating libraries... Making... No make necessary Making... ok Migrating libraries... ok Making... Preparing... Preparing the make transaction... Adding "src/admin.hdbrole" for deploy... Adding "src/admin.hdbrole" for deploy... ok Adding "src/gm2ap.hdbanalyticprivilege" for deploy... Adding "src/gm2ap.hdbanalyticprivilege" for deploy... ok Adding "src/gm2sp.hdbstructuredprivilege" for deploy... Adding "src/gm2sp.hdbstructuredprivilege" for deploy... ok Adding "src/gm2v.hdbcalculationview" for deploy... Adding "src/gm2v.hdbcalculationview" for deploy... ok Preparing... ok Preparing the make transaction... ok Checking the uniqueness of the catalog objects in the schema "7QZP9UHWGMOQPQBN_GM2P_HDI_CONTAINER"... Checking the uniqueness of the catalog objects in the schema "7QZP9UHWGMOQPQBN_GM2P_HDI_CONTAINER"... ok Calculating dependencies... Expanding... Expanding... ok Precompiling... Precompiling "src/admin.hdbrole"... Precompiling "src/gm2ap.hdbanalyticprivilege"... Precompiling "src/gm2sp.hdbstructuredprivilege"... Precompiling "src/admin.hdbrole"... ok Precompiling "src/gm2v.hdbcalculationview"... Precompiling "src/gm2v.hdbcalculationview"... ok Precompiling "src/gm2ap.hdbanalyticprivilege"... ok Precompiling "src/gm2sp.hdbstructuredprivilege"... ok Precompiling... ok Merging... Merging... ok Error: Calculating dependencies... failed Error: Make failed (1 errors, 0 warnings): tried to deploy 4 files (effective 4), undeploy 0 files (effective 0), redeploy 0 dependent files Error: "db://gm2t" is required but not provided by any file Error: Making... failed Error: Starting make in the container "7QZP9UHWGMOQPQBN_GM2P_HDI_CONTAINER" with 4 files to deploy, 0 files to undeploy... failed Error: Could not run make Error: "db://gm2t" is required but not provided by any file Deployment to container 7QZP9UHWGMOQPQBN_GM2P_HDI_CONTAINER failed - error Error executing: CALL "7QZP9UHWGMOQPQBN_GM2P_HDI_CONTAINER#DI".MAKE(#DEPLOY, #UNDEPLOY, #FOLDERPRMS, #PRMS, ?, ?, ?); (nested message: HDI call failed) [Deployment ID: none]. Error: Error: Error executing: CALL "7QZP9UHWGMOQPQBN_GM2P_HDI_CONTAINER#DI".MAKE(#DEPLOY, #UNDEPLOY, #FOLDERPRMS, #PRMS, ?, ?, ?); (nested message: HDI call failed) (2s 822ms)

npm ERR! Linux 3.0.101-71-default npm ERR! argv "/hana/shared/HXE/xs/ea_data/vhcalhxedb/executionroot/194a7474-491c-4f94-948c-f4c3103f7ce5/app/resources/nodejs/vendor/node4.4/bin/node" "/hana/shared/HXE/xs/ea_data/vhcalhxedb/executionroot/194a7474-491c-4f94-948c-f4c3103f7ce5/app/resources/nodejs/vendor/node4.4/lib/node_modules/npm/bin/npm-cli.js" "start" npm ERR! node v4.4.6 npm ERR! npm v2.15.5 npm ERR! code ELIFECYCLE npm ERR! deploy@ start: node node_modules/sap-hdi-deploy/deploy.js npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the deploy@ start script 'node node_modules/sap-hdi-deploy/deploy.js'. npm ERR! This is most likely a problem with the deploy package, npm ERR! not with npm itself. npm ERR! Tell the author that this fails on your system: npm ERR! node node_modules/sap-hdi-deploy/deploy.js npm ERR! You can get information on how to open an issue for this project with: npm ERR! npm bugs deploy npm ERR! Or if that isn't available, you can get their info via: npm ERR! npm ERR! npm owner ls deploy npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request: npm ERR! /hana/shared/HXE/xs/ea_data/vhcalhxedb/executionroot/194a7474-491c-4f94-948c-f4c3103f7ce5/app/tomcat/temp/builder/hdi-builder/builds/build-4577747085478011748/gm2m/npm-debug.log

** End of /gm2p/gm2m Build Log ** 12:17:12 PM (Builder) Check console logs for details 12:17:12 PM (Builder) Build of /gm2p/gm2m failed.

the gm2 zip file is attached: gm2p.zip

if you cannot support it, who can?

thx, greg

rich-heilman commented 7 years ago

At first glance, my initial thought is that you have encountered the bug with .hdbcalculationviews and namespaces. In the .hdinamespace file you have removed the namespace. So to get around this bug, I believe you need to create a subfolder, perhaps call it models, and put your .hdbcalculationview inside that folder. Also make a copy of the .hdinamespace file and put it into that folder as well, and change the name space accordingly, add the gm2m into this namespace. Try to do another build.

Cheers, Rich

From: gregmisiorek [mailto:notifications@github.com] Sent: Thursday, November 24, 2016 12:24 PM To: SAP/com.sap.openSAP.hana5.example com.sap.openSAP.hana5.example@noreply.github.com Subject: [SAP/com.sap.openSAP.hana5.example] Error: "db://gm2t" is required but not provided by any file (#1)

Hi Thomas,

great class, but i'm still struggling with exposing any data in views.

the full error console error dump:

12:17:03 PM (Builder) Build of /gm2p/gm2m started. 12:17:05 PM (DIBuild) Build of /gm2p/gm2m in progress 12:17:12 PM (DIBuild) ** Printing /gm2p/gm2m Build Log ** [INFO] Injecting source code into builder... [INFO] Source code injection finished [INFO] ------------------------------------------------------------------------ sap-hdi-deploy@2.0.0mailto:sap-hdi-deploy@2.0.0 node_modules/sap-hdi-deploy ├── async@1.4.2mailto:async@1.4.2 ├── sap-xsenv@1.2.2mailto:sap-xsenv@1.2.2 (debug@2.2.0mailto:debug@2.2.0, verror@1.6.0mailto:verror@1.6.0) └── hdb@0.5.3mailto:hdb@0.5.3

deploy@ start /hana/shared/HXE/xs/ea_data/vhcalhxedb/executionroot/194a7474-491c-4f94-948c-f4c3103f7ce5/app/tomcat/temp/builder/hdi-builder/builds/build-4577747085478011748/gm2m node node_modules/sap-hdi-deploy/deploy.js

sap-hdi-deploy, version 2.0.0 Collecting files... Collecting files... ok (0s 2ms) Processing grants files... Processing grants files... ok (0s 0ms) Preprocessing files... Preprocessing files... ok (0s 2ms) Synchronizing files with the container "7QZP9UHWGMOQPQBN_GM2P_HDI_CONTAINER"... 4 modified or added files are scheduled for deploy 0 deleted files are scheduled for undeploy Synchronizing files with the container "7QZP9UHWGMOQPQBN_GM2P_HDI_CONTAINER"... ok (0s 983ms) Deploying to the container "7QZP9UHWGMOQPQBN_GM2P_HDI_CONTAINER"... Starting make in the container "7QZP9UHWGMOQPQBN_GM2P_HDI_CONTAINER" with 4 files to deploy, 0 files to undeploy... Migrating libraries... Making... No make necessary Making... ok Migrating libraries... ok Making... Preparing... Preparing the make transaction... Adding "src/admin.hdbrole" for deploy... Adding "src/admin.hdbrole" for deploy... ok Adding "src/gm2ap.hdbanalyticprivilege" for deploy... Adding "src/gm2ap.hdbanalyticprivilege" for deploy... ok Adding "src/gm2sp.hdbstructuredprivilege" for deploy... Adding "src/gm2sp.hdbstructuredprivilege" for deploy... ok Adding "src/gm2v.hdbcalculationview" for deploy... Adding "src/gm2v.hdbcalculationview" for deploy... ok Preparing... ok Preparing the make transaction... ok Checking the uniqueness of the catalog objects in the schema "7QZP9UHWGMOQPQBN_GM2P_HDI_CONTAINER"... Checking the uniqueness of the catalog objects in the schema "7QZP9UHWGMOQPQBN_GM2P_HDI_CONTAINER"... ok Calculating dependencies... Expanding... Expanding... ok Precompiling... Precompiling "src/admin.hdbrole"... Precompiling "src/gm2ap.hdbanalyticprivilege"... Precompiling "src/gm2sp.hdbstructuredprivilege"... Precompiling "src/admin.hdbrole"... ok Precompiling "src/gm2v.hdbcalculationview"... Precompiling "src/gm2v.hdbcalculationview"... ok Precompiling "src/gm2ap.hdbanalyticprivilege"... ok Precompiling "src/gm2sp.hdbstructuredprivilege"... ok Precompiling... ok Merging... Merging... ok Error: Calculating dependencies... failed Error: Make failed (1 errors, 0 warnings): tried to deploy 4 files (effective 4), undeploy 0 files (effective 0), redeploy 0 dependent files Error: "db://gm2t" is required but not provided by any file Error: Making... failed Error: Starting make in the container "7QZP9UHWGMOQPQBN_GM2P_HDI_CONTAINER" with 4 files to deploy, 0 files to undeploy... failed Error: Could not run make Error: "db://gm2t" is required but not provided by any file Deployment to container 7QZP9UHWGMOQPQBN_GM2P_HDI_CONTAINER failed - error Error executing: CALL "7QZP9UHWGMOQPQBN_GM2P_HDI_CONTAINER#DI".MAKE(#DEPLOY, #UNDEPLOY, #FOLDERPRMS, #PRMS, ?, ?, ?); (nested message: HDI call failed) [Deployment ID: none]. Error: Error: Error executing: CALL "7QZP9UHWGMOQPQBN_GM2P_HDI_CONTAINER#DI".MAKE(#DEPLOY, #UNDEPLOY, #FOLDERPRMS, #PRMS, ?, ?, ?); (nested message: HDI call failed) (2s 822ms)

npm ERR! Linux 3.0.101-71-default npm ERR! argv "/hana/shared/HXE/xs/ea_data/vhcalhxedb/executionroot/194a7474-491c-4f94-948c-f4c3103f7ce5/app/resources/nodejs/vendor/node4.4/bin/node" "/hana/shared/HXE/xs/ea_data/vhcalhxedb/executionroot/194a7474-491c-4f94-948c-f4c3103f7ce5/app/resources/nodejs/vendor/node4.4/lib/node_modules/npm/bin/npm-cli.js" "start" npm ERR! node v4.4.6 npm ERR! npm v2.15.5 npm ERR! code ELIFECYCLE npm ERR! deploy@ start: node node_modules/sap-hdi-deploy/deploy.js npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the deploy@ start script 'node node_modules/sap-hdi-deploy/deploy.js'. npm ERR! This is most likely a problem with the deploy package, npm ERR! not with npm itself. npm ERR! Tell the author that this fails on your system: npm ERR! node node_modules/sap-hdi-deploy/deploy.js npm ERR! You can get information on how to open an issue for this project with: npm ERR! npm bugs deploy npm ERR! Or if that isn't available, you can get their info via: npm ERR! npm ERR! npm owner ls deploy npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request: npm ERR! /hana/shared/HXE/xs/ea_data/vhcalhxedb/executionroot/194a7474-491c-4f94-948c-f4c3103f7ce5/app/tomcat/temp/builder/hdi-builder/builds/build-4577747085478011748/gm2m/npm-debug.log

** End of /gm2p/gm2m Build Log ** 12:17:12 PM (Builder) Check console logs for details 12:17:12 PM (Builder) Build of /gm2p/gm2m failed.

the gm2 zip file is attached: gm2p.ziphttps://github.com/SAP/com.sap.openSAP.hana5.example/files/611902/gm2p.zip

if you cannot support it, who can?

thx, greg

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHubhttps://github.com/SAP/com.sap.openSAP.hana5.example/issues/1, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AQ7cT6ibAPCd9jD00jSJ6difCYIJ1Nfoks5rBcg8gaJpZM4K73GF.

rich-heilman commented 7 years ago

I don’t think that the calculation view problem is what is causing this error (although I think it will hit you later). I ran the build in my HANA 2 system and the error is a little more precise:

[cid:image001.png@01D24678.81B924E0]

It points directly to this structured privilege that has a select on gm2t:

STRUCTURED PRIVILEGE "gm2sp" FOR SELECT ON "gm2t" WHERE "amt" = '*'

Your gm2s.hdbcds has an entity gm2t but it’s in a context named gm2s. Therefore the name would be gm2s.gm2t.

Correcting that does lead to a new error: [cid:image002.png@01D24678.E1485700]

But this error is more to the point that you are trying to create a structured privilege on a table (entity). This is not allowed. You can only create them on views. So I think you have conceptual problems with this project.

So in your hdbcds file I added a view for the gm2t entity: view gm2tView as select from gm2t { acct, amt } with structured privilege check ;

I then changed your structured privilege to point to the view: STRUCTURED PRIVILEGE "gm2sp" FOR SELECT ON "gm2s.gm2tView" WHERE "amt" = '*'

And everything builds correctly. [cid:image003.png@01D24679.37BBD710]

However in your system, you would probably still face the namespace error with the calculation view that Rich described earlier. It isn’t a problem in my system due to the newer release having this problem solved.

Thomas Jung

From: Heilman, Rich Sent: Thursday, November 24, 2016 4:59 PM To: SAP/com.sap.openSAP.hana5.example reply@reply.github.com; greg.misiorek@att.net Cc: Jung, Thomas thomas.jung@sap.com Subject: RE: [SAP/com.sap.openSAP.hana5.example] Error: "db://gm2t" is required but not provided by any file (#1)

At first glance, my initial thought is that you have encountered the bug with .hdbcalculationviews and namespaces. In the .hdinamespace file you have removed the namespace. So to get around this bug, I believe you need to create a subfolder, perhaps call it models, and put your .hdbcalculationview inside that folder. Also make a copy of the .hdinamespace file and put it into that folder as well, and change the name space accordingly, add the gm2m into this namespace. Try to do another build.

Cheers, Rich

From: gregmisiorek [mailto:notifications@github.com] Sent: Thursday, November 24, 2016 12:24 PM To: SAP/com.sap.openSAP.hana5.example com.sap.openSAP.hana5.example@noreply.github.com<mailto:com.sap.openSAP.hana5.example@noreply.github.com> Subject: [SAP/com.sap.openSAP.hana5.example] Error: "db://gm2t" is required but not provided by any file (#1)

Hi Thomas,

great class, but i'm still struggling with exposing any data in views.

the full error console error dump:

12:17:03 PM (Builder) Build of /gm2p/gm2m started. 12:17:05 PM (DIBuild) Build of /gm2p/gm2m in progress 12:17:12 PM (DIBuild) ** Printing /gm2p/gm2m Build Log ** [INFO] Injecting source code into builder... [INFO] Source code injection finished [INFO] ------------------------------------------------------------------------ sap-hdi-deploy@2.0.0mailto:sap-hdi-deploy@2.0.0 node_modules/sap-hdi-deploy ├── async@1.4.2mailto:async@1.4.2 ├── sap-xsenv@1.2.2mailto:sap-xsenv@1.2.2 (debug@2.2.0mailto:debug@2.2.0, verror@1.6.0mailto:verror@1.6.0) └── hdb@0.5.3mailto:hdb@0.5.3

deploy@ start /hana/shared/HXE/xs/ea_data/vhcalhxedb/executionroot/194a7474-491c-4f94-948c-f4c3103f7ce5/app/tomcat/temp/builder/hdi-builder/builds/build-4577747085478011748/gm2m node node_modules/sap-hdi-deploy/deploy.js

sap-hdi-deploy, version 2.0.0 Collecting files... Collecting files... ok (0s 2ms) Processing grants files... Processing grants files... ok (0s 0ms) Preprocessing files... Preprocessing files... ok (0s 2ms) Synchronizing files with the container "7QZP9UHWGMOQPQBN_GM2P_HDI_CONTAINER"... 4 modified or added files are scheduled for deploy 0 deleted files are scheduled for undeploy Synchronizing files with the container "7QZP9UHWGMOQPQBN_GM2P_HDI_CONTAINER"... ok (0s 983ms) Deploying to the container "7QZP9UHWGMOQPQBN_GM2P_HDI_CONTAINER"... Starting make in the container "7QZP9UHWGMOQPQBN_GM2P_HDI_CONTAINER" with 4 files to deploy, 0 files to undeploy... Migrating libraries... Making... No make necessary Making... ok Migrating libraries... ok Making... Preparing... Preparing the make transaction... Adding "src/admin.hdbrole" for deploy... Adding "src/admin.hdbrole" for deploy... ok Adding "src/gm2ap.hdbanalyticprivilege" for deploy... Adding "src/gm2ap.hdbanalyticprivilege" for deploy... ok Adding "src/gm2sp.hdbstructuredprivilege" for deploy... Adding "src/gm2sp.hdbstructuredprivilege" for deploy... ok Adding "src/gm2v.hdbcalculationview" for deploy... Adding "src/gm2v.hdbcalculationview" for deploy... ok Preparing... ok Preparing the make transaction... ok Checking the uniqueness of the catalog objects in the schema "7QZP9UHWGMOQPQBN_GM2P_HDI_CONTAINER"... Checking the uniqueness of the catalog objects in the schema "7QZP9UHWGMOQPQBN_GM2P_HDI_CONTAINER"... ok Calculating dependencies... Expanding... Expanding... ok Precompiling... Precompiling "src/admin.hdbrole"... Precompiling "src/gm2ap.hdbanalyticprivilege"... Precompiling "src/gm2sp.hdbstructuredprivilege"... Precompiling "src/admin.hdbrole"... ok Precompiling "src/gm2v.hdbcalculationview"... Precompiling "src/gm2v.hdbcalculationview"... ok Precompiling "src/gm2ap.hdbanalyticprivilege"... ok Precompiling "src/gm2sp.hdbstructuredprivilege"... ok Precompiling... ok Merging... Merging... ok Error: Calculating dependencies... failed Error: Make failed (1 errors, 0 warnings): tried to deploy 4 files (effective 4), undeploy 0 files (effective 0), redeploy 0 dependent files Error: "db://gm2t" is required but not provided by any file Error: Making... failed Error: Starting make in the container "7QZP9UHWGMOQPQBN_GM2P_HDI_CONTAINER" with 4 files to deploy, 0 files to undeploy... failed Error: Could not run make Error: "db://gm2t" is required but not provided by any file Deployment to container 7QZP9UHWGMOQPQBN_GM2P_HDI_CONTAINER failed - error Error executing: CALL "7QZP9UHWGMOQPQBN_GM2P_HDI_CONTAINER#DI".MAKE(#DEPLOY, #UNDEPLOY, #FOLDERPRMS, #PRMS, ?, ?, ?); (nested message: HDI call failed) [Deployment ID: none]. Error: Error: Error executing: CALL "7QZP9UHWGMOQPQBN_GM2P_HDI_CONTAINER#DI".MAKE(#DEPLOY, #UNDEPLOY, #FOLDERPRMS, #PRMS, ?, ?, ?); (nested message: HDI call failed) (2s 822ms)

npm ERR! Linux 3.0.101-71-default npm ERR! argv "/hana/shared/HXE/xs/ea_data/vhcalhxedb/executionroot/194a7474-491c-4f94-948c-f4c3103f7ce5/app/resources/nodejs/vendor/node4.4/bin/node" "/hana/shared/HXE/xs/ea_data/vhcalhxedb/executionroot/194a7474-491c-4f94-948c-f4c3103f7ce5/app/resources/nodejs/vendor/node4.4/lib/node_modules/npm/bin/npm-cli.js" "start" npm ERR! node v4.4.6 npm ERR! npm v2.15.5 npm ERR! code ELIFECYCLE npm ERR! deploy@ start: node node_modules/sap-hdi-deploy/deploy.js npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the deploy@ start script 'node node_modules/sap-hdi-deploy/deploy.js'. npm ERR! This is most likely a problem with the deploy package, npm ERR! not with npm itself. npm ERR! Tell the author that this fails on your system: npm ERR! node node_modules/sap-hdi-deploy/deploy.js npm ERR! You can get information on how to open an issue for this project with: npm ERR! npm bugs deploy npm ERR! Or if that isn't available, you can get their info via: npm ERR! npm ERR! npm owner ls deploy npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request: npm ERR! /hana/shared/HXE/xs/ea_data/vhcalhxedb/executionroot/194a7474-491c-4f94-948c-f4c3103f7ce5/app/tomcat/temp/builder/hdi-builder/builds/build-4577747085478011748/gm2m/npm-debug.log

** End of /gm2p/gm2m Build Log ** 12:17:12 PM (Builder) Check console logs for details 12:17:12 PM (Builder) Build of /gm2p/gm2m failed.

the gm2 zip file is attached: gm2p.ziphttps://github.com/SAP/com.sap.openSAP.hana5.example/files/611902/gm2p.zip

if you cannot support it, who can?

thx, greg

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHubhttps://github.com/SAP/com.sap.openSAP.hana5.example/issues/1, or mute the threadhttps://github.com/notifications/unsubscribe-auth/AQ7cT6ibAPCd9jD00jSJ6difCYIJ1Nfoks5rBcg8gaJpZM4K73GF.

gregmisiorek commented 7 years ago

Rich/Thomas,

I got it to work by building the calc (column) view on top of another view instead of directly on top of a table. Thank you very much for your help.

greg