1. Anuncie Aqui ! Entre em contato fdantas@4each.com.br

[SQL] Running Remote Function in Linked Server

Discussão em 'Outras Linguagens' iniciado por Stack, Outubro 3, 2024 às 21:22.

  1. Stack

    Stack Membro Participativo

    I have a SQL function that simply a number of business days into a specific date. The function is running ok in the local database server. However I'm having problem running the function from linked server.

    In the local database server, this runs ok

    DECLARE @Test DATETIME
    SELECT @Test = [dbo].[AddBizDays](1,'2024-10-01')
    SELECT @Test


    Result is '2024-10-02'

    However this is not working in linked server:

    DECLARE @Test DATETIME
    SELECT @Test = [Server1].[DB1].[dbo].[AddBizDays](1,'2024-10-01')


    I got the error message: Remote function reference '[Server1].[DB1].[dbo].[AddBizDays]' is not allowed, and the column name 'Server1' could not be found or is ambiguous.

    Continue reading...

Compartilhe esta Página