[Modeling-cvs] ProjectModeling/Modeling ModelValidation.py,1.9,1.10
Status: Abandoned
Brought to you by:
sbigaret
|
From: <sbi...@us...> - 2003-06-24 10:22:00
|
Update of /cvsroot/modeling/ProjectModeling/Modeling
In directory sc8-pr-cvs1:/tmp/cvs-serv11022
Modified Files:
ModelValidation.py
Log Message:
Changes: I formerly announced on the ml. that a varchar w/o width would issue a message at the INFO level --the previous changes simply discarded it
Index: ModelValidation.py
===================================================================
RCS file: /cvsroot/modeling/ProjectModeling/Modeling/ModelValidation.py,v
retrieving revision 1.9
retrieving revision 1.10
diff -C2 -d -r1.9 -r1.10
*** ModelValidation.py 24 Jun 2003 08:51:10 -0000 1.9
--- ModelValidation.py 24 Jun 2003 10:21:57 -0000 1.10
***************
*** 354,360 ****
msgs.append("NUMERIC type requires both 'precision' AND 'scale'")
elif extType in ('varchar', 'char'):
! if not attribute.width() and \
! concreteAdaptorName not in ('Postgresql', 'SQLite'):
! msgs.append("CHAR/VARCHAR type requires 'width' to be set")
elif extType in ('integer',):
if attribute.width() or attribute.width() or attribute.precision():
--- 354,362 ----
msgs.append("NUMERIC type requires both 'precision' AND 'scale'")
elif extType in ('varchar', 'char'):
! if not attribute.width():
! if concreteAdaptorName not in ('Postgresql', 'SQLite'):
! msgs.append("CHAR/VARCHAR type requires 'width' to be set")
! else: # INFO
! errors.aggregateError('Attribute %s.%s'%(attribute.entity().name(), attribute.name()), INFO, "ANSI SQL requires that a (VAR)CHAR has its width set (but %s accepts it)"%concreteAdaptorName)
elif extType in ('integer',):
if attribute.width() or attribute.width() or attribute.precision():
|