SQL script execution Fails in CRM

Hi Community,

Have used the objects inside the SQL scripts for creating views and try to install it,but the installation failing in creatio with the error "No such object found" . Is there any specific way to define objects inside the SQL scripts ? Is SQL script execution process is missing in CRM ? 

 

Thanks in advance!

 

Like 0

Like

4 comments

Hi, that's the correct way to do it. Are you using SQL or Postgres?  Do you want to share the create view script you are using? 

Best regards!

Hi, I am using SQL script. Please find my script below for creating view.

'UsrShow' is the object which i created in my app.

 

IF OBJECT_ID('UsrShow', 'V') IS NOT NULL BEGIN
    DROP VIEW UsrShow;
END
GO

CREATE VIEW UsrShow (
        Id,
        Name
    ) AS
SELECT
    NEWID() [Id],
    UsrShow.Name
FROM UsrShow

 

It shows below error

 

I donno what i am missing here.  Is there anything to set to the object when calling it in view ? Can you please let me know how to work out this.

 

Thanks!

Paviyathachayini Mahendran,

 

Hello!

 

You receive a PostgreSQL exception upon executing a query written for MS SQL. You need to rewrite your query to be used in PostgreSQL.

Hi,

Thank You for the quick response. When i tried a script in PostgreSql it gets installed successfully. But could you please let me how to use this script or stored procedure inside the creatio application  ? like pulling data in a report based on the Stored procedure execution results ..

Show all comments