Changeset 362 for PersistentData/Backend/UPDClientMySQL.pas
- Timestamp:
- May 10, 2012, 1:18:25 PM (13 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
PersistentData/Backend/UPDClientMySQL.pas
r361 r362 50 50 resourcestring 51 51 SMissingBaseType = 'Missing base typ for %s'; 52 SUndefinedType = 'Undefinned type %s'; 53 SCantLoadObjectWithoutId = 'Can''t load object without id'; 52 SUndefinedType = 'Undefined type in %0:s.%1:s'; 54 53 55 54 … … 172 171 for I := 0 to AType.Properties.Count - 1 do 173 172 with AType.Properties do begin 174 RefType := T ypes.SearchByName(Items[I].Value);173 RefType := TPDTypeProperty(Items[I]).DbType; 175 174 if not Assigned(RefType) then 176 raise Exception.Create(Format(SUndefinedType, [ Items[I].Value]));175 raise Exception.Create(Format(SUndefinedType, [AType.Name, TPDTypeProperty(Items[I]).Name])); 177 176 if RefType.DbType = '' then 178 177 raise Exception.Create(Format(SMissingBaseType, [RefType.Name])); 179 178 180 Query := Query + '`' + Items[I].Key+ '` ' + RefType.DbType + ' NULL,';179 Query := Query + '`' + TPDTypeProperty(Items[I]).Name + '` ' + RefType.DbType + ' NULL,'; 181 180 end; 182 181 Query := Query + 'PRIMARY KEY (`Id`)' +
Note:
See TracChangeset
for help on using the changeset viewer.