----boundary-LibPST-iamunique-668891966_-_-
Content-type: text/plain
Bart,
another aspect to your question is that holding more than one global
reference to a database object would prevent the effective use of the
so-called anchor controls; because you would also have to include several
anchor controls into your form in such a situation. For more details on
anchor controls please refer to the Sql subsystem's developer manual.
Cheers
Marc
Oberon microsystems, Inc.
> -----Original Message-----
> From: Wijck, Bart van [mailto:Bart.van.Wijck{([at]})nowhere.xy> Sent: Donnerstag, 8. Juli 2004 12:45
> To: 'blackbox{([at]})nowhere.xy> Subject: Closing a database
>
>
> Hi BlackBox people,
>
> Can anyone answer the following question:
>
> As long as you are processing a database with SQL you need
> database and table objects. When you are done processing you
> set these object pointers to NIL. With the explicit command
> Kernel.Cleanup the garbage collector closes the database, or
> I presume this happens anyway when you are finish executing
> altogether. The point obviously is not to keep the database
> open longer than necessary.
>
> What I do not understand why BlackBox advises to make the
> database pointer a local variable and only export the table
> pointer. Yes you can at anytime recreate the database pointer
> form the table pointer via:
>
> db := <sybsytem>.rt.base; (* where rt is the result table
> pointer *)
>
> But what is the big difference? The presumably large chunk of
> memory where the database object is allocated is retained in
> any case until all (!) references to it are set to NIL. So
> even if db is local and presumably set to NIL automatically
> when the procedure in which it is defined has finished
> executing, there's still the reference to it in rt.base
> (which is global and exported). Closing the database still
> needs to be done explicitly by setting rt := NIL.
>
> So why not export both objects and set them to NIL when needed?
>
> Regards, Bart
>
>
>
>
>
>
> --
> The contents of this e-mail are intended for the named
> addressee only. It contains information that may be
> confidential. Unless you are the named addressee or an
> authorized designee, you may not copy or use it, or disclose
> it to anyone else. If you received it in error please notify
> us immediately and then destroy it.
>
> --------------------------------------------
>
> To unsubscribe from this mailing list, send a message
> containing the word "unsubscribe" to:
> blackbox-request{([at]})nowhere.xy>
> To get a list of valid e-mail commands and instructions on
> their usage, send a message containing the word "help" to the
> above address.
>
> Send any problem reports or questions related to this email
> list to the list owner at
> owner-blackbox{([at]})nowhere.xy>
> Current posting policy:
>
> a) To post you should use the same address by which you are
> subscribed to the mailing list. That way, the list server
> will recognize you as subscriber and forward your posting
> immediately, without creating any overhead.
>
> b) If, for some reason, you cannot post from the address, by
> which you are subscribed, your message will be moderated to
> avoid spam. Please understand that moderation will often
> cause some delay, in particular over weekends or holydays.
>
--------------------------------------------
To unsubscribe from this mailing list, send a message containing the word "unsubscribe" to:
blackbox-request{([at]})nowhere.xy
To get a list of valid e-mail commands and instructions on their usage, send a message containing the word "help" to the above address.
Send any problem reports or questions related to this email list to the list owner at
owner-blackbox{([at]})nowhere.xy
Current posting policy:
a) To post you should use the same address by which you are subscribed to the mailing list. That way, the list server will recognize you as subscriber and forward your posting immediately, without creating any overhead.
b) If, for some reason, you cannot post from the address, by which you are subscribed, your message will be moderated to avoid spam. Please understand that moderation will often cause some delay, in particular over weekends or holydays.
----boundary-LibPST-iamunique-668891966_-_-
Content-type: application/rtf
Content-transfer-encoding: base64
Content-Disposition: attachment; filename="rtf-body.rtf"
e1xydGYxXGFuc2lcYW5zaWNwZzEyNTJcZnJvbXRleHQgXGRlZmYwe1xmb250dGJsDQp7XGYwXGZz
d2lzcyBBcmlhbDt9DQp7XGYxXGZtb2Rlcm4gQ291cmllciBOZXc7fQ0Ke1xmMlxmbmlsXGZjaGFy
c2V0MiBTeW1ib2w7fQ0Ke1xmM1xmbW9kZXJuXGZjaGFyc2V0MCBDb3VyaWVyIE5ldzt9fQ0Ke1xj
b2xvcnRibFxyZWQwXGdyZWVuMFxibHVlMDtccmVkMFxncmVlbjBcYmx1ZTI1NTt9DQpcdWMxXHBh
cmRccGxhaW5cZGVmdGFiMzYwIFxmMFxmczIwIEJhcnQsXHBhcg0KXHBhcg0KYW5vdGhlciBhc3Bl
Y3QgdG8geW91ciBxdWVzdGlvbiBpcyB0aGF0IGhvbGRpbmcgbW9yZSB0aGFuIG9uZSBnbG9iYWxc
cGFyDQpyZWZlcmVuY2UgdG8gYSBkYXRhYmFzZSBvYmplY3Qgd291bGQgcHJldmVudCB0aGUgZWZm
ZWN0aXZlIHVzZSBvZiB0aGVccGFyDQ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