Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

some errors about ReinitializeDatabase (C#) #18

Open
jqrv opened this issue Nov 5, 2019 · 4 comments
Open

some errors about ReinitializeDatabase (C#) #18

jqrv opened this issue Nov 5, 2019 · 4 comments

Comments

@jqrv
Copy link

jqrv commented Nov 5, 2019

when I ReinitializeDatabase , the framework start to create table .
but some times, it doesn't add [RowID] column to the client.

as I know, if a table whithout RowID then can't sync.

I've created 2 tables on the server, test and test2.
when I click ReinitializeDatabase button
test2 has no [Rowid] column,but test has!

I add the exist table to sync(call AddTable API) always get this error.

here is the ReinitializeDatabase response content:

we can see about the create table test2 code, it really has no [RowID]!

there is a 'rowid' in the test table:

"00014 test" : "CREATE TABLE "test" ([id] INTEGER ,[name] TEXT DEFAULT ('NULL') ,[age] INTEGER DEFAULT (NULL) ,[birthday] DATETIME ,[RowId] TEXT DEFAULT ('NULL') ,"MergeUpdate" INTEGER NOT NULL DEFAULT (0) );",

but,there is not a 'rowid' in the test2 table.

"00007 test2" : "CREATE TABLE "test2" ([id] INTEGER ,[country] TEXT DEFAULT ('NULL') ,[city] TEXT DEFAULT ('NULL') ,[code] INTEGER DEFAULT (NULL) ,"MergeUpdate" INTEGER NOT NULL DEFAULT (0) );",

@jqrv jqrv changed the title some errors about C# code ReinitializeDatabase some errors about ReinitializeDatabase (C#) Nov 5, 2019
@jqrv
Copy link
Author

jqrv commented Nov 6, 2019

I found the reason.
when you use addtable api to add a table to sync ,or change your master db schema.
you should restart tomcat!

@sqlite-sync
Copy link
Owner

sqlite-sync commented Nov 6, 2019 via email

@jqrv
Copy link
Author

jqrv commented Nov 10, 2019

you are right.

@sqlite-sync
Copy link
Owner

sqlite-sync commented Dec 2, 2019 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants