hi,
please give answer
CREATE PROCEDURE Prcexpincview
please give answer
CREATE PROCEDURE Prcexpincview
(
@month varchar(50),
@year varchar(50)
)
as
SELECT tblexpense.expname,tblexpense.expamount,tblpayments.vpayment
FROM dnalabsoft.tblexpense FULL OUTER JOIN
dnalabsoft.tblpayments ON dnalabsoft.tblexpense.ipaymentid = dnalabsoft.tblpayments.ipaymentid
where month(dbilldate)=@month and year(dbilldate)=@year group by expname
Error Occured
Error Occured
Msg 209, Level 16, State 1, Procedure Prcexpincview, Line 11
Ambiguous column name 'dbilldate'.
Msg 209, Level 16, State 1, Procedure Prcexpincview, Line 11
Ambiguous column name 'dbilldate'.
8 Replies
Know the answer? Post it — somebody with the same question will find it here.
Sign in to answer this question
It is the same account you read, post and publish with — and you will come straight back to this page.
Ramesh MaruthiPosted Sep 23, 2014, 11:02 AM
Ravi KumarPosted Sep 23, 2014, 6:08 AM
year(E.dbilldate)=@year group by expname
Maneesh A NPosted Sep 23, 2014, 6:02 AM
Ravi KumarPosted Sep 23, 2014, 4:20 AM
year(P.dbilldate)=@year group by expname
Maneesh A NPosted Sep 23, 2014, 4:10 AM
Ravi KumarPosted Sep 23, 2014, 3:01 AM
tell your requirement.
what is out put you want.
Maneesh A NPosted Sep 23, 2014, 2:49 AM
how to join with these two tables with where
tblexpense
ipaymentid int
tblpayments
ibookingid int
vpatientname varchar(50)
vtest varchar(50)
vpayment decimal(18, 0)
vbillnum varchar(50)
dbilldate datetime
Ravi KumarPosted Sep 23, 2014, 2:34 AM
dbilldate column is there in both tables.
give like this give tablename.dbo.dbilldate