1
0
mirror of https://github.com/django/django.git synced 2025-07-04 09:49:12 +00:00

Add get_max_name_length() method to all backend/base.py

git-svn-id: http://code.djangoproject.com/svn/django/branches/boulder-oracle-sprint@3975 bcc190cf-cafb-0310-a4f2-bffc1f526a37
This commit is contained in:
Boulder Sprinters 2006-11-04 20:41:11 +00:00
parent 5da24765c9
commit a642b4ada2
6 changed files with 18 additions and 0 deletions

View File

@ -134,6 +134,9 @@ def get_drop_foreignkey_sql():
def get_pk_default_value():
return "DEFAULT"
def get_max_name_length():
return None
OPERATOR_MAPPING = {
'exact': '= %s',
'iexact': 'LIKE %s',

View File

@ -179,6 +179,9 @@ def get_drop_foreignkey_sql():
def get_pk_default_value():
return "DEFAULT"
def get_max_name_length():
return None
OPERATOR_MAPPING = {
'exact': '= %s',
'iexact': 'LIKE %s',

View File

@ -128,6 +128,9 @@ def get_drop_foreignkey_sql():
def get_pk_default_value():
return "DEFAULT"
def get_max_name_length():
return 30
OPERATOR_MAPPING = {
'exact': '= %s',
'iexact': 'LIKE %s',

View File

@ -111,6 +111,9 @@ def get_drop_foreignkey_sql():
def get_pk_default_value():
return "DEFAULT"
def get_max_name_length():
return None
# Register these custom typecasts, because Django expects dates/times to be
# in Python's native (standard-library) datetime/time format, whereas psycopg
# use mx.DateTime by default.

View File

@ -104,6 +104,9 @@ def get_drop_foreignkey_sql():
def get_pk_default_value():
return "DEFAULT"
def get_max_name_length():
return None
OPERATOR_MAPPING = {
'exact': '= %s',
'iexact': 'ILIKE %s',

View File

@ -144,6 +144,9 @@ def get_drop_foreignkey_sql():
def get_pk_default_value():
return "NULL"
def get_max_name_length():
return None
def _sqlite_date_trunc(lookup_type, dt):
try:
dt = util.typecast_timestamp(dt)