Icon View Thread

The following is the text of the current message along with any replies.
Messages 1 to 4 of 4 total
Thread Query does not use directory of its database component
Fri, Jun 12 2009 12:44 PMPermanent Link

Uwe
Hi everyone,

I try to switch between different identical local databases.
To switch I close the query and set the "databasename" property to the name of another
TDBISAMDatabase objects "databasename".
The Directory property of this DB component points to the right path with my tables.

During call to Prepare, the query does not use the path from the DB component but the
local app directory, so does not find the tables and raises an exception.

Why the path of the DB component is ignored?
(The "datadirectory" variable of the query shows the right db name but the path of my
application)

(DBISAM 4.23 Build 2 CS, Delphi 7)

Thanks
Uwe Held
Fri, Jun 12 2009 1:24 PMPermanent Link

Tim Young [Elevate Software]

Elevate Software, Inc.

Avatar

Email timyoung@elevatesoft.com

Uwe,

<< I try to switch between different identical local databases. To switch I
close the query and set the "databasename" property to the name of another
TDBISAMDatabase objects "databasename". The Directory property of this DB
component points to the right path with my tables.

During call to Prepare, the query does not use the path from the DB
component but the local app directory, so does not find the tables and
raises an exception.

Why the path of the DB component is ignored?  (The "datadirectory" variable
of the query shows the right db name but the path of my application) >>

Are you using an explicit TDBISAMSession component ?  If so, then make sure
that your TDBISAMDatabase and TDBISAMQuery components all have their
SessionName property set to the same value as the SessionName property of
the TDBISAMSession component.

--
Tim Young
Elevate Software
www.elevatesoft.com

Fri, Jun 12 2009 4:19 PMPermanent Link

Uwe
Tim,

> Are you using an explicit TDBISAMSession component ?  If so, then make sure ...

No - default session (single user local app).

Uwe
Sat, Jun 13 2009 4:26 AMPermanent Link

Uwe
Tim,

sorry - my fault. The given Databasename property meanwhile was invalid...
nonetheless thanks.

Uwe
Image