Icon View Thread

The following is the text of the current message along with any replies.
Messages 1 to 10 of 19 total
Thread "lost" store.
Fri, Sep 21 2012 4:39 AMPermanent Link

Adam Brett

Orixa Systems

I have a JOB which iterates the STORES on a session:

PREPARE StoreStmt FROM
' SELECT
 Name
 FROM Configuration."Stores" ';

OPEN StoreCrsr;
FETCH FIRST FROM StoreCrsr ('Name') INTO StoreName;
WHILE NOT EOF(StoreCrsr) DO
  ...work here.
  FETCH NEXT FROM StoreCrsr ('Name') INTO StoreName;
  END WHILE;

It is working fine, but generating an error:

ElevateDB Error #401 The store FullwellMillSunderlandBackUp does not exist in the configuration EDBConfig

FullwellMillSunderlandBackUp is a store which I DROPPED some time ago.

Strangely when I run the SQL statement:

SELECT
 Name
 FROM Configuration."Stores"

I do not see FullwellMillSunderlandBackUp listed in the result-set, so I don't know why it is appearing when the SCRIPT is run as a JOB.
Fri, Sep 21 2012 9:49 AMPermanent Link

Fernando Dias

Team Elevate Team Elevate

Adam,

Most likely you are using a different configuration file; have you checked that ?

--
Fernando Dias
[Team Elevate]
Fri, Sep 21 2012 11:03 AMPermanent Link

Roy Lambert

NLH Associates

Team Elevate Team Elevate

Adam


Obvious first thought - are you looking at two different config files?

Roy Lambert [Team Elevate]
Wed, Sep 26 2012 3:48 AMPermanent Link

Adam Brett

Orixa Systems

Thanks for this Roy:

>>Obvious first thought - are you looking at two different config files?

I guess this probably is what is happening. However, I can't figure out how that could be the case!

When a JOB is run, does it look at a different catalogue file from the one I would be using from EDBMgr & how is it possible to check for this & correct it?

I have always assumed that the JOBs only work with what I would be seeing in EDBMgr.

Adam
Wed, Sep 26 2012 9:34 AMPermanent Link

Roy Lambert

NLH Associates

Team Elevate Team Elevate

Adam


I haven't used any JOBS myself yet but looking within EDBManager they, and the stores, seem to be defined at the session level so they are available to all the databases within that session.

Are you running a test in EDBManager and a real life version and comparing the two? If so check that the config folder is the same in both cases.

Roy Lambert [Team Elevate]
Wed, Sep 26 2012 10:03 AMPermanent Link

Adam Brett

Orixa Systems

Thanks Roy.

For others reading this thread, adding

USING [databasename];

to the SQL of the JOB narrows down the range of STORES which it looks at ...
Thu, Sep 27 2012 5:29 AMPermanent Link

Fernando Dias

Team Elevate Team Elevate

Adam,

<< For others reading this thread, adding USING [databasename];
to the SQL of the JOB narrows down the range of STORES which it looks at
....>>

If it does, it shouldn't.
The USING statement changes the execution context of a JOB to another
database (by default JOBS execute within the context of the Configuration
database),  it shouldn't change the visible stores as stores are also
defined at configuration-level, and thus not dependent on what database is
considered the 'current' database.
Can you give us an example of what you are seeing?

--
Fernando Dias
[Team Elevate]
Thu, Sep 27 2012 11:05 AMPermanent Link

Adam Brett

Orixa Systems

>>If it does, it shouldn't.

OK: I am sure you are right, sorry if I am misleading others.

What happened was, I had a STORE which I deleted. When I later ran the JOB (which was using a SQL Statement to retrieve a list of available stores) the deleted store was still present.

A while later I amended the JOB adding the USING & it worked ... so I assumed that was what fixed it.

Now I have removed the USING & it is still working Smile

So I am unsure why it was finding the deleted store for a while. My error, or some reference surviving as a ghost in the OS?
Thu, Sep 27 2012 1:48 PMPermanent Link

Fernando Dias

Team Elevate Team Elevate

Adam,

<< So I am unsure why it was finding the deleted store for a while. My error, or some reference surviving as a ghost in the OS? >>

Naah Smiley
I still think the cause was, as Roy and me told you before, at some point you were using 2 different configuration files. You can check what configuration file you are using by checking:

For File Sharing mode (stLocal sessions):
* In your applications: TEDBEngine.ConfigPath or the TEDBSession.LocalConfigPath
* In EDB Manager : Right-click the session on the tree/Edit Session...
  then Select the "Local" tab and check 'File Folder'

For Client Server mode (stRemote applications):
* In the "edbsrvr.ini" file, at the server, look for the "Configuration Folder" entry.
  (This file is by default in the App Data folder - in Win 7 it's C:\ProgramData\Elevate Software\ElevateDB Server) .

--
Fernando Dias
[Team Elevate]
Fri, Sep 28 2012 4:16 AMPermanent Link

Roy Lambert

NLH Associates

Team Elevate Team Elevate

Fernando

><< So I am unsure why it was finding the deleted store for a while. My error, or some reference surviving as a ghost in the OS? >>
>
>Naah Smiley
>I still think the cause was, as Roy and me told you before, at some point you were using 2 different configuration files. You can check what configuration file you are using by checking:

Just thinking: if the config was in-memory and the PC not shut down it might (Tim will know) be possible that the data wasn't refreshed properly. If then EDBManager was closed and re-opened, or the PC rebooted the new data would be loaded.

Roy Lambert [Team Elevate]
Page 1 of 2Next Page »
Jump to Page:  1 2
Image