Arun Kumar Menon
Member
- Joined
- Nov 26, 2006
- Messages
- 9
- Programming Experience
- Beginner
Dear gurus
select null APPNTDATE,TO_char(b.TIMESLOT, 'HH24:MI') apttime,null pin,null name,null telephone,null remarks,null appointmento,doccode,
comp_code,div_code,0 intappno,0 yearcode from EDDOCTORDYSLOT b
where (b.COMP_CODE = ?)
AND (b.DIV_CODE = ?)
AND (b.DOCCODE = ?)
and TO_char(b.TIMESLOT, 'HH24:MI') not in(SELECT to_char(a.APPNTTIME,'hh24:mi')
FROM CMS.EDTRAPPOINTMENT a
WHERE (a.COMP_CODE = ?)
AND (a.DIV_CODE = ?)
AND (a.YEARCODE = ?)
AND (a.DOCCODE = ?)
AND (a.APPNTDATE = ?)
I am novice and am trying to run this query in an oledbadaptor. I have generated the dataset and during run time i am trying to fill the dataset it gives an error saying object instance not set.
If i remove the subquery i am getting the records in the dat set.
appreciate all help
thanks and regards
Arun
select null APPNTDATE,TO_char(b.TIMESLOT, 'HH24:MI') apttime,null pin,null name,null telephone,null remarks,null appointmento,doccode,
comp_code,div_code,0 intappno,0 yearcode from EDDOCTORDYSLOT b
where (b.COMP_CODE = ?)
AND (b.DIV_CODE = ?)
AND (b.DOCCODE = ?)
and TO_char(b.TIMESLOT, 'HH24:MI') not in(SELECT to_char(a.APPNTTIME,'hh24:mi')
FROM CMS.EDTRAPPOINTMENT a
WHERE (a.COMP_CODE = ?)
AND (a.DIV_CODE = ?)
AND (a.YEARCODE = ?)
AND (a.DOCCODE = ?)
AND (a.APPNTDATE = ?)
I am novice and am trying to run this query in an oledbadaptor. I have generated the dataset and during run time i am trying to fill the dataset it gives an error saying object instance not set.
If i remove the subquery i am getting the records in the dat set.
appreciate all help
thanks and regards
Arun