this is seshu i have problem in formating the date actualy the data base iam using is mysql which is following yyyy-mm-dd format where as in my front end ie vb.net the date format is different for that reason i wrote my code like this
Expand|Select|Wrap|Line Numbers
- dim sdt as date
- dim str as string
- sdt =datetimepicker1.text
- textbox1.text=format(sdt,yyyy-MM-dd)
- str="select EmpID,EmpName,EmpLogin,EmpLogout,EmpLogDate,status from checkout where EmpID = '" & ComboBox1.Text & "','" & TextBox1.Text & "' < EmpLogDate < '" & TextBox2.Text & "'"
- Dim myda As New Odbc.OdbcDataAdapter(str, myconnection)
- Dim myds As New DataSet
- myds.Clear()
- myda.Fill(myds, "checkout")
- DataGridView1.DataSource = myds.Tables(0)
but i wrote the same code with connection string
empdate=current_date there it is working well so i came to a conclution that is is problem with date type or the format some one please help me out
regards
seshu