... 相当する SQL を示しています。同じパターンがすべての空間ルックアップに適用されます。 ケース ルックアップ 等価なSQL N, B rast__contains=rst ST_Contains(rast, rst) N, B rast__1__contains=(rst, 2) ST_Contains(rast, 1, rst, 2) B, C rast__contains=geom ST_Contai ... ns(ST_Polygon(rast), geom) B, C rast__1__contains=geom ST_Contains(ST_Polygon(rast, 1), geom) B, C poly__contains=rst ST_Contains(poly, ST_Polygon(rst)) B, C poly__contains ... =(rst, 1) ST_Contains(poly, ST_Polygon(rst, 1)) C rast__crosses=rst ST_Crosses(ST_Polygon(rast), ST_Polygon(rst)) C rast__1__crosses=(rst, 2) ST ... ... 200 ) tags = ArrayField ( models . CharField ( max_length = 200 ), blank = True ) def __str__ ( self ): return self . name contains ArrayField 上で contains ルックアップはオーバーライドされます。返されるオブジェクトは、渡された値がデータの部分集合であるも ... >>> Post . objects . create ( name = "Third post" , tags = [ "tutorial" , "django" ]) >>> Post . objects . filter ( tags__contains = [ "thoughts" ]) <QuerySet [<Post: First post>, <Post: Second post>]> >>> Post . objects . filter ( tags__contains = [ "d ... jango" ]) <QuerySet [<Post: First post>, <Post: Third post>]> >>> Post . objects . filter ( tags__contains = [ "django" , "thoughts" ]) <QuerySet [<Post: First post>]> contained_by これは contains ルックアップの逆です。返されるオ ... ... (<field>__<lookup_type>=<parameter>) >>> qs = Zipcode.objects.exclude(...) 例: >>> qs = Zipcode . objects . filter ( poly__contains = pnt ) >>> qs = Elevation . objects . filter ( poly__contains = rst ) この場合、 poly は地理情報フィールド、 contains は空 ... tion.objects.filter(<field>__<lookup_type>=(<raster_input, <band_index>) 例: >>> qs = Elevation . objects . filter ( rast__contains = geom ) >>> qs = Elevation . objects . filter ( rast__contains = rst ) >>> qs = Elevation . objects . filter ( rast__1__c ... ontains = geom ) >>> qs = Elevation . objects . filter ( rast__contains = ( rst , 1 )) >>> qs = Elevation . objects . filter ( rast__1__contains = ( rst , 1 )) 例の左辺では、 rast が地理情報ラス ... ... e template for the technical 500 debug page ( #30324 ). Fixed crash of ordering argument in ArrayAgg and StringAgg when it contains an expression with params ( #30332 ). Fixed a regression in Django 2.2 that caused a single instance fast-delete to not se ... 0 ). Prevented makemigrations from generating infinite migrations for check constraints and partial indexes when condition contains a range object ( #30350 ). Reverted an optimization in Django 2.2 ( #29725 ) that caused the inconsistent behavior of coun ... when using StatReloader ( #30323 ). Fixed a migration crash on Oracle and PostgreSQL when adding a check constraint with a contains , startswith , or endswith lookup (or their case-insensitive variant) ( #30408 ). Fixed a migration crash on Oracle and SQ ... ... __startswith = "What" ) >>> q = q . filter ( pub_date__lte = datetime . date . today ()) >>> q = q . exclude ( body_text__icontains = "food" ) >>> print ( q ) この例ではデータベースに3回アクセスしているように見えますが、実際にアクセスしているのは、最終行 ... beatles blog" ) は "Beatles Blog" 、 "beatles blog" 、あるいは "BeAtlES blOG" というタイトルを持つ Blog にもマッチします。 contains case-sensitive な部分一致テストを行います。たとえば、 Entry . objects . get ( headline__contains = "Lennon" ) はだいたい次 ... n honored' にはマッチしても 'today lennon honored' にはマッチしないことに注意してください。 case-insensitive バージョンの icontains もあります。 startswith と endswith それぞれ starts-with と ends-with 検索を行います。case-insensitive バージョン istartsw ... ... ize yourself with the basics of how Git works. Git's website offers downloads for various operating systems. The site also contains vast amounts of documentation . The Django Git repository is located online at github.com/django/django . It contains the ... full source code for all Django releases, which you can browse online. The Git repository includes several branches : main contains the main in-development code which will become the next packaged release of Django. This is where most development activit ... fix and security releases which occur as necessary after the initial release of a feature version. The Git repository also contains tags . These are the exact revisions from which packaged Django releases were produced, since version 1.0. A number of tag ... ... rtapp コマンドラインオプション startproject コマンドラインオプション _ __bool__() (backends.base.SessionBase のメソッド) __contains__() (backends.base.SessionBase のメソッド) (QueryDict のメソッド) __delitem__() (backends.base.SessionBase のメソッド) (Ht ... ager のメソッド) aclear_expired() (backends.base.SessionBase のメソッド) aconfigure_user() (RemoteUserBackend のメソッド) acontains() (django.db.models.query.QuerySet モジュール) ACos (django.db.models.functions のクラス) acount() (django.db.models.query ... egates のクラス) ArrayField (django.contrib.postgres.fields のクラス) arrayfield.contained_by field lookup type arrayfield.contains field lookup type arrayfield.index field lookup type arrayfield.len field lookup type arrayfield.overlap field lookup type ... ... じめて貢献する How-to ガイド If you already have some familiarity with the processes and principles, our documentation also contains useful guidance on specific topics: How to submit a patch to Django for new and/or fixed behavior How to write and run tes ... ... ping.org/downloads/TM_WORLD_BORDERS-0.3.zip ...\> unzip TM_WORLD_BORDERS-0.3.zip ...\> cd ..\.. The world borders ZIP file contains a set of data files collectively known as an ESRI Shapefile , one of the most popular geospatial data formats. When unzipp ... file' successful. 1: TM_WORLD_BORDERS-0.3 (Polygon) ogrinfo tells us that the shapefile has one layer, and that this layer contains polygon data. To find out more, we'll specify the layer name and use the -so option to get only the important summary info ... kup) GeoDjango adds spatial lookups to the Django ORM. For example, you can find the country in the WorldBorder table that contains a particular point. First, fire up the management shell: / $ python manage.py shell ...\> py manage.py shell ここで、注 ... ... edicate) メソッドは、別の GEOSGeometry インスタンス ( other ) をパラメータとして受け取り、真偽値を返します。 GEOSGeometry. contains ( other ) other.within(this) が True を返した場合に True を返します。 GEOSGeometry. covers ( other ) このジオメトリが指定し ... , ***T**FF* , または ****T*FF* である。 どちらかのジオメトリが空の場合、 False を返します。 この predicate は GEOSGeometry.contains() に似ていますが、より包括的です (つまり、より多くの場合に True を返します) 。特に、 contains() とは異なり、ジオメトリの境 ... 界と内部の点を区別しません。ほとんどの場合、 contains() よりも covers() を優先すべきです。さらに、 covers() は最適化しやすいので、 contains() よりも優れています。 GEOSGeometry. ... 2026年10月08日