...
Code Block | ||||
---|---|---|---|---|
| ||||
EdmiError edmiRemoteOpenRepository(SdaiServerContext serverContextId,
SdaiString remoteRepositoryName,
SdaiAccessMode openMode,
SdaiString superUserPassword,
SdaiClientId clientId,
SdaiOptions options,
SdaiRepository *repositoryId,
SdaiInvocationId *edmiInvocationId);
|
This function has two areas of application;
...
Insert excerpt | ||||||
---|---|---|---|---|---|---|
|
Options
...
Option | Comment |
ALL_SERVERS | Open the repository from all the EDMapplicationServer processes in the EDMserverRoom. |
...
Example
...
Code Block | ||||
---|---|---|---|---|
| ||||
/* Open selected repositories and models to initialize a remote database */ int i; EdmiError rstat; SdaiServerContext suContext; SdaiRepository repositoryId; SdaiModel modelId; SdaiQueryResult qexRes; SdaiInteger nRepository, nModel; SdaiInteger index; /* Define Remote Server Context for the superuser */ rstat = edmiDefineServerContext( "SuperUserContext", "superuser", NULL, "xfx56kl9", "TCP", "9090", "MyServerHost", NULL, NULL, NULL, NULL, NULL, &suContext); /* Find and open all repositories in the database that is not the 'SystemRepository', 'DictionaryRepository' or 'EDMvisualExpress' repository */ index = 0; rstat = edmiRemoteSelectInstances( suContext, "SystemRepository", "ExpressDataManager", "EDM_REPOSITORY", "(NAME <> 'SystemRepository') AND \ (NAME <> 'DictionaryRepository') AND \ (NAME <> 'EDMvisualExpress')", 0, "NAME", NULL, NULL, &index, &nRepository, &qexRes, NULL, NULL, NULL, NULL); for (i=0;i<nRepository;i++) { rstat = edmiRemoteOpenRepository(suContext, ((SdaiString *) qexRes->columnDescr[0]->pvalue)[i], sdaiRW, "xfx56kl9", 0, ALL_SERVERS, &repositoryId, NULL); } edmiFreeQueryResult(qexRes); /* Find and open all models in the database that is not in the 'SystemRepository', 'DictionaryRepository' or 'EDMvisualExpress' repository */ index = 0; rstat = edmiRemoteSelectInstances( suContext, "SystemRepository", "ExpressDataManager", "EDM_MODEL", "(REPOSITORY.NAME <> 'SystemRepository') AND \ (REPOSITORY.NAME <> 'DictionaryRepository') AND \ (REPOSITORY.NAME <> 'EDMvisualExpress')", 0, "REPOSITORY.NAME NAME", NULL, NULL, &index, &nModel, &qexRes, NULL, NULL, NULL, NULL); for (i=0;i<nModel;i++) { rstat = edmiRemoteOpenModel( suContext, ((SdaiString *) qexRes->columnDescr[0]->pvalue)[i], ((SdaiString *) qexRes->columnDescr[1]->pvalue)[i], sdaiRW, "xfx56kl9", 0, 0, &modelId, NULL); } edmiFreeQueryResult(qexRes); . . . |
See also
Filter by label (Content by label) | ||||||
---|---|---|---|---|---|---|
|