CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 4 of 4
  1. #1
    Join Date
    Apr 2014
    Posts
    6

    selecting data of same date and time..

    Hello

    I have design one GUI and storing data of that in database with date and time.

    i am taking few sequence from the user for any single date and time. and storing that into database.

    now i want to start thread when that date and time ocurre. but i don't know how to take data from database which has today's date and time.

    can any one give me c# code for that.

    i have used in built SQL server database and C#.

    i am just putting my logic here below.


    while(1)
    {
    if(today's date match with database date)
    {
    if(time match with database time)
    {
    my logic
    }
    }
    }

  2. #2
    Arjay's Avatar
    Arjay is offline Moderator / EX MS MVP Power Poster
    Join Date
    Aug 2004
    Posts
    13,490

    Re: selecting data of same date and time..

    What do you use to read the data out of the database?

  3. #3
    Join Date
    Apr 2014
    Posts
    6

    Re: selecting data of same date and time..

    Quote Originally Posted by Arjay View Post
    What do you use to read the data out of the database?
    I have stored few sequences on same date and time with frequency. so I want to first check whether today's date match in database so, I want to select all rows with today's date and then from that I want to start task on stored time and then I am going to write my logic to the particular sequence for a delay given by user so, that logic I have shown in my first question but I don't understand that how to implement that using C#.

    my stored date is in date format and time is in time(7) format.

  4. #4
    Arjay's Avatar
    Arjay is offline Moderator / EX MS MVP Power Poster
    Join Date
    Aug 2004
    Posts
    13,490

    Re: selecting data of same date and time..

    Again, what are you doing to read the data out of the database?

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  





Click Here to Expand Forum to Full Width

Featured