I doubt that's the problem.

I have KeyField = "project,team,quota" and the exact same fieldnames in
my database. And that is stored correctly in the dataset when using new
or requery.


-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]
On Behalf Of Ed Leafe
Sent: 9. januar 2008 14:50
To: Dabo Users list
Subject: Re: [dabo-users] Problem with BizObj save

On Jan 8, 2008, at 6:15 PM, Nate Lowrie wrote:

> I have a bizobj that is a standard bizobj.  Here's the code.
>
> class CustomerBizobj(dabo.biz.dBizobj):
>       def afterInit(self):
>               self.addFrom("customers")
>               self.addField("LastName")
>               self.addField("FirstName")
>               self.addField("Address")
>               self.addField("City")
>               self.addField("State")
>               self.addField("ZipCode")
>               self.addField("ID")
>               
>               self.KeyField = "ID"
>               self.NonUpdateFields=["ID"]

        Looking through the code, I'm wondering if this is a
capitalization  
issue. The code to check for changed records looks for the value of  
the PK field in the record, and if the cursor gets the field name  
back as "id", and you have KeyField set to "ID", it will never find  
the matching PK in the mementos.

        After you run new(), can you add a line and let me know what is

printed out?

biz.new()
print biz.getDataSet(rows=1)[0].keys()


-- Ed Leafe
-- http://leafe.com
-- http://dabodev.com




[excessive quoting removed by server]

_______________________________________________
Post Messages to: Dabo-users@leafe.com
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