I'm doing the step-by-step guide for appian developer where we're recreating the Acme Automobile example application and I encountered an error when trying to display the vehicle images in the grid.
I followed all the points in the step by step guide exactly and the error I keep encountering is the following:
Expression evaluation error at function a!gridField_23r3 [line 51]: A grid component [label="null"] has an invalid value for "columns". A grid column [label="Image"] has encountered an error. Expression evaluation error at function a!imageField [line 5]: User Does Not Have Rights to Perform this Operation
The expression I'm using to display the image is the following:
if( a!isNullOrEmpty( fv!row[recordType!W#SA Vehicle.fields.image] ), a!EXAMPLE_DOCUMENT_IMAGE(), fv!row[recordType!W#SA Vehicle.fields.image] )
where the W#SA is only a placeholder and I have replaced it with my own prefix of course (references work).
If anyone has any suggestions or guidance for why this might have happened please let me know.
Thanks.
Discussion posts and replies are publicly visible
This is a known problem. I suggest to write to academy@appian.com.
Thanks for the reply. If it's a known problem there's probably a know solution to this?
I will write to the e-mail you provided and if I get a known solution for this I'll post it here. Who knows it might help someone in the future
So, I've managed to find out the root cause for this - replying here to you if you might let someone know.
The issue here was that the initial DB created by appian on the learning servers (AFAIK this is only on the germany server) adds one row to the database where the image field is set to a number and not left empty. In my case the number was set to 11191 in the very last row. This represents an ID by which the image is found and since there is no initial images in the application folders the runtime crashed with the error reported above.
My current fix was to add a condition to look for this ID and ignore it (show the default image in that case also).
I'm guessing that a permanent fix would be to look at the scripts which create the initial database for this learning project (table AS Vehicle) and make sure the image rows are all set to empty. Not sure how and when these tables are created but this was the issue.
Thanks!
Thank you very much for this info. I really hope Appian refines the deployment script to avoid this issue. I know that someone at Appian is aware of it.