The column prefix ''dbo'' does not match with a table name or alias name used in the query.

  • Not sure what I'm doing wrong here...but in my function I have

          DECLARE @CountryName VARCHAR(50)

     

          SELECT @CountryName =

          Descrip FROM [myDB].[dbo].[syCountry]

          WHERE [myDB].[dbo].[syCountry] = @CountryID

     

          RETURN(@CountryName)

    Error:

    The column prefix 'dbo' does not match with a table name or alias name used in the query.

  • are you missing the column name in the where clause?

    WHERE [myDB].[dbo].[syCountry].columnname = @CountryID

Viewing 2 posts - 1 through 1 (of 1 total)

You must be logged in to reply to this topic. Login to reply