finger trouble...
but this update did not work: ( I may have mistyped the below, but
something like it ran error-free, but no changes)
dx.fields[otherfield.first()]=dict(value=db.staging[row.staging.id].English)
I don't know if the negative ids were a factor
- Peter E
--
You received this mes
Thanks for your comment, Yarko
I had disabled the table references because the anki (non-web2py)
database has over 20 tables, including two tables that cross-reference
each other. I did not need those references for my purposes, hence the
integer fields.
I was able to successfully update the 'fie
On Mar 26, 3:46 am, Peter Etchells wrote:
> Thanks for taking the time to look at this problem.
>
> len(dx.executesql('SELECT * from fields'))
> gave 43815, ie the correct answer.
>
> I finally realized it was because the anki application for some reason
> had a negative id about 1/3 of the record
Thanks for taking the time to look at this problem.
len(dx.executesql('SELECT * from fields'))
gave 43815, ie the correct answer.
I finally realized it was because the anki application for some reason
had a negative id about 1/3 of the records.
I was just using the default query dx.fields.id > 0
I cannot reproduce the problem. I tried this
db=DAL('sqlite://storage.db')
db.define_table('fields',
Field('aaa'),
Field('value', 'text'))
db.fields.insert(aaa='aaa',value='aaa')
db.fields.insert(aaa='aaa',value=None)
db.fields.insert(aaa='aaa',value='')
db.commit()
for row in db(db.fields.id>0
5 matches
Mail list logo