G
Guest
I am open to using either a stored proceedure or an inline function to be
able to do this. I have looked trough all 12 pages in this section and it
starts to talk about what I need and then it goes off on a tangent to where I
get lost.
My query that I need to run is much more involved, but the one below will
still be able to show what I want to do and an answer on how it should be
done would be easily moved to the more complex query.
SELECT Employee, WorkDate, Customer, WorkHours
FROM dbo.tblWorkDetail
WHERE (DATEPART(Month, WorkDate) = @Pick_Month)
I want to either have a field on a form that will set the criteria or just
have an input box open that would ask for the month.
My problem lies in that I can create the function or SP but when other users
try and use it, the systems says that the object cannot be found. I gave all
uses full permission on the SQL object so that isn't it, but when I look at
the SP in SQL it looks like this:
CREATE PROCEDURE [domainname\myname].StoredProcedure1(@Pick_Month
nvarchar(50))
AS SELECT Employee, WorkDate, Customer, WorkHours
FROM dbo.tblWorkDetail
WHERE (DATEPART(Month, WorkDate) = @Pick_Month)
GO
and I think it is because of the domainname\myname that I am having the issue.
Is there a way to open this like a query window that all can use?
I have tried with connection objects, I have tried making tables that do not
show up until you refresh the table list for some reason, etc. I am at wits
end for something that was so simple with an mdb.....
able to do this. I have looked trough all 12 pages in this section and it
starts to talk about what I need and then it goes off on a tangent to where I
get lost.
My query that I need to run is much more involved, but the one below will
still be able to show what I want to do and an answer on how it should be
done would be easily moved to the more complex query.
SELECT Employee, WorkDate, Customer, WorkHours
FROM dbo.tblWorkDetail
WHERE (DATEPART(Month, WorkDate) = @Pick_Month)
I want to either have a field on a form that will set the criteria or just
have an input box open that would ask for the month.
My problem lies in that I can create the function or SP but when other users
try and use it, the systems says that the object cannot be found. I gave all
uses full permission on the SQL object so that isn't it, but when I look at
the SP in SQL it looks like this:
CREATE PROCEDURE [domainname\myname].StoredProcedure1(@Pick_Month
nvarchar(50))
AS SELECT Employee, WorkDate, Customer, WorkHours
FROM dbo.tblWorkDetail
WHERE (DATEPART(Month, WorkDate) = @Pick_Month)
GO
and I think it is because of the domainname\myname that I am having the issue.
Is there a way to open this like a query window that all can use?
I have tried with connection objects, I have tried making tables that do not
show up until you refresh the table list for some reason, etc. I am at wits
end for something that was so simple with an mdb.....