here my code-
create function dbo.emptable()
returns Table
as
return (select id, name, salary from employee)
go
select dbo.emptable()
error: Msg 4121, Level 16, State 1, Line 1 Cannot find either column "dbo" or the user-defined function or aggregate "dbo.emptable", or the name is ambiguous.
while when I run
sp_helptext emptable
it shows-
create function dbo.emptable()
returns Table
as
return (select id, name, salary from employee)
it means function exists in database then why it is giving such error?