how to select date

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • aziz sonnari
    New Member
    • Dec 2013
    • 2

    how to select date

    dear
    I am working with vb project but facing difficulty in getting Records = 0 if date 01/11/2014 when I check database found 2 records see foolowing code

    Mdate =Formaat(rs3!sh edual,"dd/mm/yyyy")
    rs.close
    rs.open"select * from shedual where EffeDate=#" & Mdate & "#"
    thank you
  • twinnyfo
    Recognized Expert Moderator Specialist
    • Nov 2011
    • 3662

    #2
    aziz sonnari,

    First, it is most helpful to us if you copy and paste your code directly from your VB project, as it is clear that your code would from a formatting perspective. Also, please use the Code Tags when posting code.

    Second, because you've only posted a very short snippet of your code, we don't know what rs3 is referring to. Then you close a different recordset (we can only assume) and then reopen it again. It is difficult to decipher what you are trying to do from the code supplied. Additionally, it does not look like you are actually searching for the date 1/11/2014, but only the value found in rs3!shedual.

    If you provide us a few more details and explanation we will be glad to assist you.

    Comment

    Working...