Ticket #14629: 14629_sqlite.patch

File 14629_sqlite.patch, 1.2 KB (added by jdemeyer, 7 years ago)
  • sage/databases/cremona.py

    # HG changeset patch
    # User Jeroen Demeyer <jdemeyer@cage.ugent.be>
    # Date 1369317340 -7200
    # Node ID b1c9477b19394a76be595b4267b93caca8944cf9
    # Parent  f78a9f50409f259e0ac45749b7d550eabf0ec47d
    Sort iterator through Cremona database by conductor
    diff --git a/sage/databases/cremona.py b/sage/databases/cremona.py
    a b  
    99is included by default with Sage.  It contains Weierstrass equations,
    1010rank, and torsion for curves up to conductor 10000.
    12 The large database includes all curves of conductor up to 240,000. It
     12The large database includes all curves of conductor up to 300,000. It
    1313also includes data related to the BSD conjecture and modular degrees
    1414for all of these curves, and generators for the Mordell-Weil
    1515groups. To install it type the following in Sage::
    645645            sage: it.next().label()
    646646            '45a3'
    647647        """
    648         for c in self.__connection__.cursor().execute('SELECT curve FROM ' \
    649             + 't_curve'):
     648        query = "SELECT curve FROM t_curve,t_class USING(class) ORDER BY conductor"
     649        for c in self.__connection__.cursor().execute(query):
    650650            yield self.elliptic_curve(c[0])
    652652    def __getitem__(self, N):