G
G
GromWolf2017-02-05 16:36:36
Python
GromWolf, 2017-02-05 16:36:36

How to make a fetch from ms sql server 16?

There is a program in python, it connects to a database (sql server 2016). The program should take turns pulling values ​​from the tables. The table has 2 columns. The first time I need to pull out the value of column 1, row 1, then column 1, row 2, and so on. That is, a cycle is needed. How to properly handle this. Thanks in advance

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
d-stream, 2017-02-05
@GromWolf

If "next time" is, for example, tomorrow, then apparently somewhere you need to store the last read position and, based on its value, query it. If this is "in a row" - then it's better to count everything (unless, of course, it's millions of lines) and only then it spins, for example, in a loop.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question