i have a problem when i'm executing msync in a pocket with WINCE 6.1 in oracle lite 10G this is the log:
MAGIC_CHECK returned incorrect for srmo.DC_AUX_TRABJORN
MAGIC_CHECK returned incorrect for srmo.DC_MA_RECLAMO
MAGIC_CHECK returned incorrect for srmo.DC_REC_ATENCION
MAGIC_CHECK returned incorrect for srmo.DC_REC_ATENCION_PROG
MAGIC_CHECK returned incorrect for srmo.DC_REC_MATERIAL
MAGIC_CHECK returned incorrect for srmo.DC_REC_RESPONSABLE
MAGIC_CHECK returned incorrect for srmo.DC_REC_SEGUIMIENTO
MAGIC_CHECK returned incorrect for srmo.MV_EMPLEADOS
MAGIC_CHECK returned incorrect for srmo.V_ALIMENTADOR_PUB
MAGIC_CHECK returned incorrect for srmo.V_CAUSAFALLA
MAGIC_CHECK returned incorrect for srmo.V_FALLA_EN
MAGIC_CHECK returned incorrect for srmo.V_MATERIALESRastreo de pila de excepciones de sesión de sincronización:
java.sql.SQLException: ORA-02020: too many database links in use
at oracle.lite.sync.Subscription.execPrepDirect(Unknown Source)
at oracle.lite.sync.HeliosSession.sendPayload(Unknown Source)
at oracle.lite.sync.HeliosSession.sendSubData(Unknown Source)
at oracle.lite.sync.HeliosSession.downloadSubs(Unknown Source)
at oracle.lite.sync.HeliosSession.startSession(Unknown Source)
at oracle.lite.sync.resume.Client$1.run(Unknown Source)
at oracle.lite.sync.resume.ThreadPool$PoolTask.run(Unknown Source)
The problem is that i have 2 publications with the same USER(s) on MOBILESERVERS (requeriment) and both ocupy datalinks and this is a really bad because one of them is not development by me
how can i avoid this "too many database link in use" this resolves with a rollback but how i do this if i cant access the code of LITE's MSYNC.exe?
Thanks in advice friends
Edited by: santiagofmg on 29-mar-2012 16:10
Edited by: santiagofmg on 29-mar-2012 16:16
you have 2 users with the same name on the server, you sync from the client and you get the error on the server or on the client?
"but how i do this if i cant access the code of LITE's MSYNC.exe"
you cant access the code of msync , but you can use the synchronization api directly, which is pretty much the same just without the graphical window with the bars. on the handheld you have one database connection active per time right?when i say one i mean that when you execute msync you disconnect your aplication from the database. by the way i think that you can specify the publication that you want to sync if you execute the msync through code. you can even specify a specific table , so you can sync one table per time.
Thanks for your time
And yes i have one user with 2 applications, and i have to sync both applications.
the first sync i use Msync.exe in the PDA the next ones i make it with C# code
Can you tell me please how you synchronize just one app at a time. thats could resolve my problem.
to be honest im not sure that this is your problem, but we had a problem with sync on windows mobile 6.1 devices and after talking to the oracle lite reps they told us that we must always have ONE connection open to the oracle lite database on the handheld(client) . this includes the msync.
this means that when we sync from our handheld with c# code we disconnect from the database before sync. also if your planning to have the msync running then you must make sure that your c# app is not connected.
what we have done to our projects is to execute the msync THROUGH the c# olite apis (you not the command that brings up the msync interface. we do that through our c# code. before we execute it we close the database connection, when sync ends we open it again. this had solved our problems. if your planning to running the msync out side your app, from start->programs->msync then in your app you must open conn execute select/insert/delet statement then close conn each time. unfortunately this will make it slower. if i were you i wouldnt allow running msync directly from the handheld but only through the program (c#). this way you can open close connections so you only have 1 connection at the database at any given time.
but as i said im not sure this is your case. this would be if the error occured when you are running your app with the connection on and then try to run msync in the same time (or something like that?)
but from the look of your problem im not sure if the problem lies on the handheld database or on the server database.
Edited by: vasileios on Apr 11, 2012 10:42 PM
I explain better
I have 2 applications A and B. in the mobile Server i had several users some of them access aplication A and some others access aplication B.
The problem lies when i have a user who access both aplications A and B. giving ORA-02020 too many database links in use when i am sync.
too many database links in use
Cause: The current session has exceeded the INIT.ORA open_links maximum.
Action: Increase the open_links limit, or free up some open links by committing or rolling back the transaction and canceling open cursors that reference remote databases.
i did that and doesn't work or how can i know the correct number for open_links based in the premise that this parameter = 4 (default) I increase it to 8 based on pure logic 'cause with 4 works well for 1 aplication 8 work for both aplications.
ok ive never run into this,if i were you i would try the following
1)since the number is between 1-255 give it a go with a higher value than 8. i suppose you need to restart the oracle database (11g?) in order to apply the setting
2)since this is an oracle lite server -to oracle database error i would contact customer service (open service request).btw i didnt find anything in knowledge base about this and oracle lite
3)did you try through your c# code to sync for one publication at a time? i mean from the handheld sync 1st publication, finish, then sync 2nd pub. i suppose each of your applications have a diffrent publication , so you should have 2 applciation->2 publications->2 database schemas->1 database instance(1mobileadmin schema).
i know this might sound trivial but you do have all the patches installed right?
Thanks for your time
The solution in fact is to sync just one application but i dont know how. Because when i am sync from my c# code internaly it reads that user1 have access to application A and B (it is preconfigured on mobileserver) and i dont know how to discrimine and make that the class who make the sync just sync with application A.
if you could help me with some tips on C# to make this thanks
Sorry my english its not my mother languaje.
String args =UserUsernameCodeWord + "/" + UserPassword + "@" + ServerIPAddress+" /onlytable:EMPLOYEES";
if you want not just one table but one publication use onlypub
so if you have 2 application lets say cars and houses then you SHOULD have 2 publications carspub and housespub
then you write
String args =UserUsernameCodeWord + "/" + UserPassword + "@" + ServerIPAddress+" /onlypub:carspub";
String args =UserUsernameCodeWord + "/" + UserPassword + "@" + ServerIPAddress+" /onlypub:housespub";
personally i prefer to use the oracleengine.synchronize cause it pops that nice gui with the bars and saves me from the trouble of making one of my own:)
(im a lazy programmer:P)
dont forget before the synchronize to close any connection the your application has to the database
olite says it suppurts the onlyapp also but i havent used that one myself.
Synchronize only specific Web-to-Go application data. Do not synchronize with other applications.
Synchronize only specific publication data. Do not synchronize with other publications.
Synchronize only specific table data. Do not synchronize with other tables.