On Monday 17 September 2007 10:34, Ed Leafe wrote:
> On Sep 17, 2007, at 1:23 PM, johnf wrote:
> > Thanks that should work as all my forms contain at least one bizobj
> > that is
> > the same for all forms.
>
>       Good, because it is generally not a good idea in a 3-tier framework
> to jump from UI directly to the data layer.
>
> -- Ed Leafe
I'm now using 

curnewlot= oForm.agschgridBizobj.getTempCursor()       
##oForm.conn.getDaboCursor()

and I still get a similar traceback and _storeFieldTypes() is still being 
called.


Traceback (most recent call last):
  File "/home/johnf/downloads/dabo/dabo/ui/uiwx/dControlMixin.py", line 21, in 
_
onWxHit
    self.raiseEvent(dEvents.Hit, evt, *args, **kwargs)
  File "/home/johnf/downloads/dabo/dabo/ui/uiwx/dPemMixin.py", line 843, in 
rais
eEvent
    super(dPemMixin, self).raiseEvent(eventClass, nativeEvent, *args, 
**kwargs)
  File "/home/johnf/downloads/dabo/dabo/lib/eventMixin.py", line 92, in 
raiseEve
nt
    bindingFunction(event)
  File "/home/johnf/pyProject/pyProject/RAClasses.py", line 1189, in onSave
    self.Form.save()
  File "/home/johnf/downloads/dabo/dabo/ui/uiwx/dForm.py", line 343, in save
    bizobj.saveAll()
  File "/home/johnf/downloads/dabo/dabo/biz/dBizobj.py", line 278, in saveAll
    startTransaction=False)
  File "/home/johnf/downloads/dabo/dabo/biz/dBizobj.py", line 693, in 
scanChange
dRows
    func(*args, **kwargs)
  File "/home/johnf/downloads/dabo/dabo/biz/dBizobj.py", line 323, in save
    self._validate()
  File "/home/johnf/downloads/dabo/dabo/biz/dBizobj.py", line 891, in 
_validate
    message = self.validateRecord()
  File "/home/johnf/pyProject/pyProject/LotsBizobj.py", line 146, in 
validateRec
ord
    
clot=getNewLot(self.MainForm,datetime.date.today().year,self.getFieldVal('fk
_species'),self.getFieldVal('fk_variety'),self.getFieldVal('fk_origin'))
  File "/home/johnf/pyProject/pyProject/RAClasses.py", line 2398, in getNewLot
    curnewlot.execute("select nextval('public.lot_seq') as nextlot, 
s.speciesnum                                            , v.varnum, 
o.norigincode from public.agspecies s left join public.agvarieties v            
                                 
on true left join public.agorigins o on true where s.pkid=%s and v.pkid=%s 
and                                             o.pkid=%s" % 
(sppk,varpk,oripk,))
  File "/home/johnf/downloads/dabo/dabo/db/dCursorMixin.py", line 311, in 
execut                                            e
    self._storeFieldTypes()
  File "/home/johnf/downloads/dabo/dabo/db/dCursorMixin.py", line 434, in 
_store                                            FieldTypes
    for field in self.DataStructure:
  File "/home/johnf/downloads/dabo/dabo/db/dCursorMixin.py", line 2120, in 
_getD                                            ataStructure
    ds = self.BackendObject.getStructureDescription(self)
  File "/home/johnf/downloads/dabo/dabo/db/dBackend.py", line 460, in 
getStructu                                            reDescription
    standard_fields = cursor.getFields()
  File "/home/johnf/downloads/dabo/dabo/db/dCursorMixin.py", line 1710, in 
getFi                                            elds
    return self.BackendObject.getFields(tableName, self.AuxCursor)
  File "/home/johnf/downloads/dabo/dabo/db/dbPostgreSQL.py", line 86, in 
getFiel                                            ds
    localTableName = tableNameBreak[1]
IndexError: list index out of range


-- 
John Fabiani


_______________________________________________
Post Messages to: [email protected]
Subscription Maintenance: http://leafe.com/mailman/listinfo/dabo-users
Searchable Archives: http://leafe.com/archives/search/dabo-users
This message: http://leafe.com/archives/byMID/dabo-users/[EMAIL PROTECTED]

Reply via email to