4 Replies Latest reply on Jun 3, 2020 2:29 PM by ZacD

    REST Definition Export Missing Comments

    ZacD

      Hello,

       

      I'm using ORDS 19.4 and SQL Developer 19.4.  When I attempt to export the REST definition of one of my modules using SQL Developer, I am getting a script that has NULL for all of the comments:

       

       

       

      If I use the ORDS_METADATA.ords_export.export_module API to export the definition, it returns with the comments as expected:

       

       

       

      Is this a know bug with SQL Developer, or do I perhaps have some setting wrong somewhere?

        • 1. Re: REST Definition Export Missing Comments
          Mike Kutz

          Check the SQL Logs to see what the SQL statement is being ran to generate the REST Definition.

           

          MK

          • 2. Re: REST Definition Export Missing Comments
            ZacD

            When I run the command to export the REST definition, SQL Developer is executing these queries:

             

            select * from (select x.id id, x.name name, label, x.description description,
                                        (select listagg(y.role_name,'|^|') within group (order by y.role_name)
                                            from user_ords_privilege_roles y where x.name=y.privilege_name) as selected_role_names,
                                        (select listagg(y.module_name,'|^|') within group (order by y.module_name)
                                            from user_ords_privilege_modules y where x.name=y.privilege_name) as selected_module_names,
                                        (select listagg(y.pattern,'|^|') within group (order by y.pattern)
                                            from user_ords_privilege_mappings y where x.name=y.name) as patterns
                                  from user_ords_privileges x, user_ords_schemas y
                                  where (x.id <> 1) and (:SCHEMA = parsing_schema) and (y.id=x.schema_id)); --"SCHEMA"="XXORDS"
            
            select id, name, bind_variable_name, source_type, access_method, param_type from user_ords_parameters where handler_id = :HANDLER_ID order by name; --"HANDLER_ID"=16796
            
            select id, source_type, method, mimes_allowed, items_per_page, source from user_ords_handlers where template_id = :TEMPLATE_ID order by method; --"TEMPLATE_ID"=16795
            
            select id, name, bind_variable_name, source_type, access_method, param_type from user_ords_parameters where handler_id = :HANDLER_ID order by name; --"HANDLER_ID"=16790
            
            select id, source_type, method, mimes_allowed, items_per_page, source from user_ords_handlers where template_id = :TEMPLATE_ID order by method; --"TEMPLATE_ID"=16789
            
            select id, uri_template, priority, etag_type, etag_query from user_ords_templates where module_id = :MODULE_ID order by uri_template; --"MODULE_ID"=12140
            
            • 3. Re: REST Definition Export Missing Comments
              thatJeffSmith-Oracle

              That would be a bug, yes

              • 4. Re: REST Definition Export Missing Comments
                ZacD

                Thanks for confirming.  I've opened up an SR on MOS for this.