Method field returning incorrect value

Trevor DeVore lists at mangomultimedia.com
Fri Jul 29 13:50:52 CDT 2005


Hi,

On a Macintosh G5 using Revolution and the Valentina 1.11 XCMD (also  
tested on a G4) I am creating a new database using SQL commands.  I  
then open the database in my program on the mac and everything looks  
fine.

If I export the database and open it in my program using windows  
there is one query that returns incorrect data for only 1 of the  
records.  There is one method field in one record that returns a  
value of 22 rather than 1.  22 is a value in another record returned  
in the query.  But if I close my application and launch it again then  
the data returned is correct and everything works fine.

The method field is supposed to return the value of another field in  
the table which is of the same type and definition.  This is to get  
around the inability to do SELECT myField as MyFieldSomething in SQL  
with Valentina 1.

I tried opening the db in viSQL on Windows, closing it, and then  
opening my program but still saw the same result.  Then I tried  
opening the db in viSQL, executing the query I use in the program to  
fetch the records, closing the db and then opening it again in my  
program and the db worked correctly the first time.  Apparently  
running the query causes everything to work correctly.  The odd thing  
is that the data returned in viSQL is correct.

So then I decided to run that same query in my export code.  After  
creating the new Valentina db I ran the SELECT query and then closed  
the DB.  I moved the database to Windows and everything worked as  
expected.

I tried runnning REINDEX, COMPACT and DEFRAGMENT after exporting but  
that didn't seem to help. The method field that returns the wrong  
value for the one record is a ULong indexed and doesn't accept nulls.

Has anyone else ever seen anything similar to this?

-- 
Trevor DeVore
Blue Mango Multimedia
trevor at mangomultimedia.com



More information about the Valentina mailing list