Count down from 0 to 5 seconds and repeat [closed]

King or Queen-Which piece is which?

How to prevent cables getting intertwined

How "fast" do astronomical events occur?

Print the new site header

Digital signature that is only verifiable by one specific person

What is the precise meaning of "подсел на мак"?

Why swap space doesn't get filesystem check at boot time?

Why was New Asgard established at this place?

How to address players struggling with simple controls?

Is a sequel allowed to start before the end of the first book?

Why "amatus est" instead of "*amavitur"

Co-worker is now managing my team. Does this mean that I'm being demoted?

How can I ping multiple IP addresses at the same time?

In windows systems, is renaming files functionally similar to deleting them?

In a Fish that is not a Fish

How do I become a better writer when I hate reading?

Do details of my undergraduate title matter?

I wish, I yearn, for an answer to this riddle

What is this airplane that sits in front of Barringer High School in Newark, NJ?

Fill the maze with a wall-following Snake until it gets stuck

How do credit card companies know what type of business I'm paying for?

Is there any possible way to get these hearts as Adult Link?

What kind of chart is this?

Operator currying: how to convert f[a,b][c,d] to a+c,b+d?



Count down from 0 to 5 seconds and repeat [closed]







.everyoneloves__top-leaderboard:empty,.everyoneloves__mid-leaderboard:empty,.everyoneloves__bot-mid-leaderboard:empty margin-bottom:0;








2















What query can I use to trigger a count down from 0 to 5 seconds whenever executed? When I execute a query the output has to be 0 second to 5 second and once 5 seconds are done again it should go back to 0. When I execute again it should start from 0 to 5 seconds. Is it possible to achieve something like this using sql query?










share|improve this question













closed as unclear what you're asking by marcello miorelli, Colin 't Hart, Andriy M, Marco, mustaccio Jun 3 at 14:36


Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.













  • 1





    Can I just clarify, do you want to output a count after each second, or just simply wait for 5 seconds. You say the "output" has to be 0 to 5 seconds

    – George.Palacios
    May 31 at 14:44






  • 2





    It's unclear what you're actually hoping to achieve here. Certainly, you don't want to just show a countdown on the screen or waste CPU cycles. What are you going to do with this countdown? Other tools are probably more appropriate than a database for them.

    – jpmc26
    Jun 1 at 9:38











  • "Count down from 0 to 5"? Do you mean 0, 1, 2, 3, 4, 5 or 5, 4, 3, 2, 1, 0?

    – John Eisbrener
    Jun 3 at 13:26

















2















What query can I use to trigger a count down from 0 to 5 seconds whenever executed? When I execute a query the output has to be 0 second to 5 second and once 5 seconds are done again it should go back to 0. When I execute again it should start from 0 to 5 seconds. Is it possible to achieve something like this using sql query?










share|improve this question













closed as unclear what you're asking by marcello miorelli, Colin 't Hart, Andriy M, Marco, mustaccio Jun 3 at 14:36


Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.













  • 1





    Can I just clarify, do you want to output a count after each second, or just simply wait for 5 seconds. You say the "output" has to be 0 to 5 seconds

    – George.Palacios
    May 31 at 14:44






  • 2





    It's unclear what you're actually hoping to achieve here. Certainly, you don't want to just show a countdown on the screen or waste CPU cycles. What are you going to do with this countdown? Other tools are probably more appropriate than a database for them.

    – jpmc26
    Jun 1 at 9:38











  • "Count down from 0 to 5"? Do you mean 0, 1, 2, 3, 4, 5 or 5, 4, 3, 2, 1, 0?

    – John Eisbrener
    Jun 3 at 13:26













2












2








2


1






What query can I use to trigger a count down from 0 to 5 seconds whenever executed? When I execute a query the output has to be 0 second to 5 second and once 5 seconds are done again it should go back to 0. When I execute again it should start from 0 to 5 seconds. Is it possible to achieve something like this using sql query?










share|improve this question














What query can I use to trigger a count down from 0 to 5 seconds whenever executed? When I execute a query the output has to be 0 second to 5 second and once 5 seconds are done again it should go back to 0. When I execute again it should start from 0 to 5 seconds. Is it possible to achieve something like this using sql query?







sql-server






share|improve this question













share|improve this question











share|improve this question




share|improve this question










asked May 31 at 14:37









svisveshsvisvesh

192




192




closed as unclear what you're asking by marcello miorelli, Colin 't Hart, Andriy M, Marco, mustaccio Jun 3 at 14:36


Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.









closed as unclear what you're asking by marcello miorelli, Colin 't Hart, Andriy M, Marco, mustaccio Jun 3 at 14:36


Please clarify your specific problem or add additional details to highlight exactly what you need. As it's currently written, it’s hard to tell exactly what you're asking. See the How to Ask page for help clarifying this question. If this question can be reworded to fit the rules in the help center, please edit the question.









  • 1





    Can I just clarify, do you want to output a count after each second, or just simply wait for 5 seconds. You say the "output" has to be 0 to 5 seconds

    – George.Palacios
    May 31 at 14:44






  • 2





    It's unclear what you're actually hoping to achieve here. Certainly, you don't want to just show a countdown on the screen or waste CPU cycles. What are you going to do with this countdown? Other tools are probably more appropriate than a database for them.

    – jpmc26
    Jun 1 at 9:38











  • "Count down from 0 to 5"? Do you mean 0, 1, 2, 3, 4, 5 or 5, 4, 3, 2, 1, 0?

    – John Eisbrener
    Jun 3 at 13:26












  • 1





    Can I just clarify, do you want to output a count after each second, or just simply wait for 5 seconds. You say the "output" has to be 0 to 5 seconds

    – George.Palacios
    May 31 at 14:44






  • 2





    It's unclear what you're actually hoping to achieve here. Certainly, you don't want to just show a countdown on the screen or waste CPU cycles. What are you going to do with this countdown? Other tools are probably more appropriate than a database for them.

    – jpmc26
    Jun 1 at 9:38











  • "Count down from 0 to 5"? Do you mean 0, 1, 2, 3, 4, 5 or 5, 4, 3, 2, 1, 0?

    – John Eisbrener
    Jun 3 at 13:26







1




1





Can I just clarify, do you want to output a count after each second, or just simply wait for 5 seconds. You say the "output" has to be 0 to 5 seconds

– George.Palacios
May 31 at 14:44





Can I just clarify, do you want to output a count after each second, or just simply wait for 5 seconds. You say the "output" has to be 0 to 5 seconds

– George.Palacios
May 31 at 14:44




2




2





It's unclear what you're actually hoping to achieve here. Certainly, you don't want to just show a countdown on the screen or waste CPU cycles. What are you going to do with this countdown? Other tools are probably more appropriate than a database for them.

– jpmc26
Jun 1 at 9:38





It's unclear what you're actually hoping to achieve here. Certainly, you don't want to just show a countdown on the screen or waste CPU cycles. What are you going to do with this countdown? Other tools are probably more appropriate than a database for them.

– jpmc26
Jun 1 at 9:38













"Count down from 0 to 5"? Do you mean 0, 1, 2, 3, 4, 5 or 5, 4, 3, 2, 1, 0?

– John Eisbrener
Jun 3 at 13:26





"Count down from 0 to 5"? Do you mean 0, 1, 2, 3, 4, 5 or 5, 4, 3, 2, 1, 0?

– John Eisbrener
Jun 3 at 13:26










2 Answers
2






active

oldest

votes


















7














WaitFor should help you accomplish this.



In your case we can simply pass a DELAY time as below



WAITFOR DELAY '00:00:05';


This will simply wait for 5 seconds, then return to the caller.






share|improve this answer






























    6














    Have you looked into the waitfor delay command? See below example



    while 1=1
    begin
    --do something
    waitfor delay '00:00:05'
    end





    share|improve this answer





























      2 Answers
      2






      active

      oldest

      votes








      2 Answers
      2






      active

      oldest

      votes









      active

      oldest

      votes






      active

      oldest

      votes









      7














      WaitFor should help you accomplish this.



      In your case we can simply pass a DELAY time as below



      WAITFOR DELAY '00:00:05';


      This will simply wait for 5 seconds, then return to the caller.






      share|improve this answer



























        7














        WaitFor should help you accomplish this.



        In your case we can simply pass a DELAY time as below



        WAITFOR DELAY '00:00:05';


        This will simply wait for 5 seconds, then return to the caller.






        share|improve this answer

























          7












          7








          7







          WaitFor should help you accomplish this.



          In your case we can simply pass a DELAY time as below



          WAITFOR DELAY '00:00:05';


          This will simply wait for 5 seconds, then return to the caller.






          share|improve this answer













          WaitFor should help you accomplish this.



          In your case we can simply pass a DELAY time as below



          WAITFOR DELAY '00:00:05';


          This will simply wait for 5 seconds, then return to the caller.







          share|improve this answer












          share|improve this answer



          share|improve this answer










          answered May 31 at 14:41









          George.PalaciosGeorge.Palacios

          3,219827




          3,219827























              6














              Have you looked into the waitfor delay command? See below example



              while 1=1
              begin
              --do something
              waitfor delay '00:00:05'
              end





              share|improve this answer



























                6














                Have you looked into the waitfor delay command? See below example



                while 1=1
                begin
                --do something
                waitfor delay '00:00:05'
                end





                share|improve this answer

























                  6












                  6








                  6







                  Have you looked into the waitfor delay command? See below example



                  while 1=1
                  begin
                  --do something
                  waitfor delay '00:00:05'
                  end





                  share|improve this answer













                  Have you looked into the waitfor delay command? See below example



                  while 1=1
                  begin
                  --do something
                  waitfor delay '00:00:05'
                  end






                  share|improve this answer












                  share|improve this answer



                  share|improve this answer










                  answered May 31 at 14:40









                  kevinnwhatkevinnwhat

                  91319




                  91319













                      Popular posts from this blog

                      Wikipedia:Vital articles Мазмуну Biography - Өмүр баян Philosophy and psychology - Философия жана психология Religion - Дин Social sciences - Коомдук илимдер Language and literature - Тил жана адабият Science - Илим Technology - Технология Arts and recreation - Искусство жана эс алуу History and geography - Тарых жана география Навигация менюсу

                      Bruxelas-Capital Índice Historia | Composición | Situación lingüística | Clima | Cidades irmandadas | Notas | Véxase tamén | Menú de navegacióneO uso das linguas en Bruxelas e a situación do neerlandés"Rexión de Bruxelas Capital"o orixinalSitio da rexiónPáxina de Bruselas no sitio da Oficina de Promoción Turística de Valonia e BruxelasMapa Interactivo da Rexión de Bruxelas-CapitaleeWorldCat332144929079854441105155190212ID28008674080552-90000 0001 0666 3698n94104302ID540940339365017018237

                      What should I write in an apology letter, since I have decided not to join a company after accepting an offer letterShould I keep looking after accepting a job offer?What should I do when I've been verbally told I would get an offer letter, but still haven't gotten one after 4 weeks?Do I accept an offer from a company that I am not likely to join?New job hasn't confirmed starting date and I want to give current employer as much notice as possibleHow should I address my manager in my resignation letter?HR delayed background verification, now jobless as resignedNo email communication after accepting a formal written offer. How should I phrase the call?What should I do if after receiving a verbal offer letter I am informed that my written job offer is put on hold due to some internal issues?Should I inform the current employer that I am about to resign within 1-2 weeks since I have signed the offer letter and waiting for visa?What company will do, if I send their offer letter to another company