NO

Author Topic: Question about sqlite max AND min  (Read 1437 times)

Offline timharvey

  • Member
  • *
  • Posts: 1
Question about sqlite max AND min
« on: June 16, 2024, 02:18:38 PM »
Hello, Normally Max and Min will be used like this SELECT MIN([C1]) AS Mini,MAX([C2)) AS Maxi FROM [MyTable]. But with many records, the output results take a long time.

Is there any use for faster retrieval? Thank

Offline John Z

  • Member
  • *
  • Posts: 838
Re: Question about sqlite max AND min
« Reply #1 on: June 21, 2024, 11:05:24 AM »
Hi timharvey,

I'm no expert but I reached out to a heavy user who said:

"For the Guy if he has a large number of records he must do two queries, one for max and one for min each one must be into a transaction"

Hope this helps.  This site does have SQL users but of course it is mainly about C and some assembly.

John Z