-2

I am trying to create a trigger using linked database to my Oracle Database. If I do select statement, it works that means my Linked Server is working perfectly but when I try to create trigger with it i get this error:

The object name 'TESTS..TESTSMS.YELL_CAT' contains more than the maximum number of prefixes. The maximum is 2.

See my query below.

CREATE TRIGGER Insert_Into_TempYellCat ON TESTS..TESTSMS.YELL_CAT 
after INSERT AS
BEGIN

    INSERT INTO 
    TempYellCat
    (
        TRA_DATE,
        TRA_SEQ1,
        TRA_SEQ2
    )
    SELECT 
        TRA_DATE, 
        TRA_SEQ1, 
        TRA_SEQ2
    FROM 
        TESTS..TESTSMS.YELL_CAT 
END

Please I need someone to assist.

Roman Marusyk
  • 23,328
  • 24
  • 73
  • 116
Skoten
  • 7
  • 4

1 Answers1

0

This is a dupe question. Here is the solution on SO 2 years ago.

The object name contains more than the maximum number of prefixes. The maximum is 3

Specify your schema name SQL05.ManufacturingPortal.dbo.[OPC.WriteRequests] and object name with square brackets

Isaiah3015
  • 493
  • 3
  • 11