DataGrid: "... is not a valid value..."
I have my own derived datagrid. It consists of two columns. Sometimes I get the following error when clicking in the second column: "'200' is not a valid value for 'value'. 'value' should be between 'minimum' and 'maximum'". The only hint I already found out, is, that the number given in the message (in my example the 200) is the column width of my first column. But just like I said, I click in the second column.
Any idea?
Answers (1)
1
select empid,
(select min(attandancedate) from tbl_test where empid=a1.empid and (cast(attandancedate as time) between '08:00:00' and '09:59:59')) as intime,
(select max(attandancedate) from tbl_test where empid=a1.empid and (cast(attandancedate as time) >= '17:00:00')) as outtime
from tbl_test a1 group by a1.empid
But This Query Gives Null For Emp1 As Outtime Because He Does Not Punched After 5 PM
For Ideal Case We Can Remove Time from second query because we can get last punch of any employee using max, that can be use as outtime
Please Tell If This Is Usefull.
Accepted 0
select empid, min(attendencedate) as inTime, max(attendencedate) as outTime
from temp
group by empid;