sync error

Discuss plans for a future version of HanDBase for the Google Android platform

sync error

Postby dechico » Fri Feb 20, 2015 10:49 am

handbase 4.6.316
android 4.1.2
desktop 4.7.5
handebase plus for android addon 4.6.1 R1
handbase pro for android addon 4.6.1 R1

got all my row deleted after adding a field with desktop on the empty db.

Historic explanation:
-- Create db on the Desktop
-- sync with android
-- add rows (records) with android
-- add a field with desktop
-- sync with android
-- all records deleted : must restore the db saved during sync.

I d'ont need help.
I want just to signal what could be a bug.
Logically the db should have first created the field in the android db and then transfered the records from android db to the desktop db.

Perhaps it's globally too complicated to handle such a case.
In this case the documentation should perhaps advice us not to do such an operation.
dechico
 
Posts: 5
Joined: Fri Feb 20, 2015 10:22 am

Re: sync error

Postby Brian_Houghton » Sat Feb 21, 2015 11:06 am

Hi,

Thanks for posting.

My understanding is that you added records to your database on the Android but did not sync to HanDBase Desktop prior to making changes to the structure there and that you then added installed the modified database to your Android.

Is this the correct sequence of events?

If so, the modified file did indeed overwrite the database on the handheld.

For reference, best workflow is to sync to ensure records are updated in both places prior to making structural changes to the file.

Regarding a warning, it is there but is perhaps too easily missed. It is actually at the bottom of the dialog that appears when selecting File / Install within HanDBase Desktop. A screenshot illustrating this is attached for reference.

We are really sorry that this affected you and hope it did not result in too great of data loss.
Attachments
Screen Shot 2015-02-21 at 10.03.25 AM.png
Illustration of overwrite notice
Screen Shot 2015-02-21 at 10.03.25 AM.png (15.65 KiB) Viewed 894 times
Kind Regards,
Brian Houghton, DDH Software
Brian_Houghton
 
Posts: 2246
Joined: Wed May 20, 2009 8:30 am

Re: sync error

Postby dechico » Sat Feb 21, 2015 2:44 pm

Hi
I haven't installed the file using the option: install to handheld/smartphone.
I just sync all the files.
I don't remember getting any warning or popup window during the sync.
That is perhaps the problem you could fix.

Next time I try to remeber to sync the file prior to make any db change.

Thank you for the reply.

Marc
dechico
 
Posts: 5
Joined: Fri Feb 20, 2015 10:22 am

Re: sync error

Postby dechico » Sat Feb 21, 2015 3:51 pm

Hi

Finally I suppose their would be less damages if the priority was given to db records instead of db structure.

I prefer to have to add again several fields instead of entering again hundreds of row in the tables.
That is still the case when records exist on both sides.

Regards.
Marc
dechico
 
Posts: 5
Joined: Fri Feb 20, 2015 10:22 am

Re: sync error

Postby Brian_Houghton » Sun Feb 22, 2015 9:37 pm

Hi Marc,

Thanks for following up.

Any time structure is changed the file is reinstalled. The dialog should with notice should have showed and we are sorry to read that it didn't in your case.
Kind Regards,
Brian Houghton, DDH Software
Brian_Houghton
 
Posts: 2246
Joined: Wed May 20, 2009 8:30 am

Re: sync error

Postby DavidDevaneyJr » Mon Feb 23, 2015 3:29 am

HI Marc,

After seeing your post I looked at the HanDBase Conduit Quick Start Guide and noticed that it didn't have the details on how Data is Synchronized. I went ahead and added a Thread that goes into detail about this. It includes the information about how Structure Changes override any other changes, as you are seeing.

viewtopic.php?f=19&t=3939

However, assuming you haven't changed any of the default settings for your databases there should be a backup that you can restore if needed. Your databases should be synchronized to a HanDBase folder in your Documents/My Documents folder. They will be in a folder with the name you assigned to the Partnership when you created it. EG ..\Documents\HanBase\AndroidDevice\ In that folder you'll see all of your database files but you'll also see a Backup folder. In that you'll find multiple backups of your databases, up to 10 for each by default. The file names there are in the format...

DatabaseName.PDB desktop # YYYY-MM-DD hh-mm-ss OR
DatabaseName.PDB handheld # YYYY-MM-DD hh-mm-ss

In your case you'd want to open one of the "handheld" files, where you can find the records that were "deleted". If you open that database in the HanDBase Desktop you can then go to the File menu and select "Install to Handheld/Smartphone". You'll be prompted to select the User/Partnership. When you select your Android device and then Synchronize that copy of the database will overwrite the copy on your Android device, restoring your records. At that point you can then re-edit the database on the desktop to Add the field on the desktop, or android device. If you then sync again you will have the database with all your rows/records as well as the new field. (Although after typing all that it seems you are already aware of the backups and how to restore them.) However this may help some other users in the future.
Regards,
David Devaney, Jr.
DavidDevaneyJr
 
Posts: 134
Joined: Tue May 19, 2009 11:01 pm
Location: Lake Worth, FL


Return to HanDBase for Android

Who is online

Users browsing this forum: No registered users and 1 guest

cron