Re: Custom parameter when running a sync. -
11-24-2008
, 10:14 PM
"Steve" <nobody (AT) home (DOT) com> wrote in news:492ae3f5$1@forums-1-dub of
sybase.public.sqlanywhere.mobilink:
S> Currently we're doing evaluation tests to see whether or not ML will
S> cover all the different things we're doing and I can't seem to put
S> this part together.
Yes, it can do what you want.
You may to to restructure what you want slightly as the questions will
highlight.
S> In our system we have 'plans' which are identified by unique IDs. We
S> need to be able to do a sync based on a particular plan ID.
You need to elaborate a bit on this.
1. I envision a remote having _more_ than 1 plan in it.
- Is this correct?
2. When you see a particular plan ID, are you really saying:
a) You only want to upload rows related to that plan?
b) You only want to download rows related to that plan?
c) Both A and B?
Depending on the answer to 2, this is what may have to change based
on LastDownload timestamp. But I will elaborate further when you
provide answers.
S> Now I'm thinking this needs to be done by a user defined parameter
S> but am not sure if I'm doing this right.
Again, much depends on the questions above.
I would do this 1 of 2 ways:
1. Insert the plan ID into a table which uploads the row. The
download_cursor scripts join to this table and download only the
rows specified via the plan ID uploaded.
2. Use the authentication parameters to pass "x" number of parameters
to your scripts. Using this authenticate_parameters event allows
you to create as many used defined named parameters as you
require. Then just reference those in your scripts.
Without knowing more of what you need and why you are doing it this
way I would be leaning towards #1.
S> The other issue is how do I pass the ID via dbmlsync when making
S> the sync call?
If #1, insert into a table.
If #2, use the -ap switch.
--
David Fishburn
Certified ASA Developer Version 8
iAnywhere Solutions - Sybase
Professional Services
Please only post to the newsgroup
Please ALWAYS include version and MORE importantly BUILD number with
EACH post (dbeng11 -v).
EBFs and Maintenance Releases
http://downloads.sybase.com/
Developer Community / Whitepapers
http://www.ianywhere.com/developer
Case-Express - to report bugs
http://case-express.sybase.com
CodeXchange - Free samples
http://ianywhere.codexchange.sybase....ctDocumentList
Documentation
http://dcx.sybase.com/ |