Error while activating a procedure
I am trying a create a basic procedure but I am getting a error while activating it. Below is the snippet for your reference:
CREATE PROCEDURE get_bp_address_by_role_sql (
in partnerrole NVARCHAR(3),
out bp_addresses tt_bp_addresses
SQL SECURITY INVOKER
READS SQL DATA AS
SELECT a."PartnerId", a."Partnerrole", a."EmailAddress", a."CompanyName", a."AddressId",
b."City", b."PostalCode", b."Street"
FROM "SAP_HANA_DEMO"."sap.hana.democontent.epm.data::EPM.MD.BusinessPartner" as a
INNER JOIN "SAP_HANA_DEMO"."sap.hana.democontent.epm.data::EPM.MD.Addresses" as b
ON a."AddressId" = b."AddressId"
WHERE a."PartnerRole" = :partnerrolr;
The logical table type associate with this procedure is as below -
create type tt_bp_addresses as table (
I am getting the below error during activation -
invalid column name: A.AddressId: line 8 col 8 (at pos 643)
I have verified the column names in EMP.hdbdd files and hence assuming that the column name is correct but fail to understand the reason behind the exception. I would be grateful if someone can help me out here.