Login ProductsSalesSupportDownloadsAbout |
Home » Technical Support » DBISAM Technical Support » Support Forums » DBISAM Client/Server » View Thread |
Messages 1 to 6 of 6 total |
Multiple Connections to Server |
Tue, Nov 27 2007 4:18 AM | Permanent Link |
"Mark Gibson" | Hi Folks, I have an app that connects to the data remotely via the dbsvr. I
have one session for the data and another local session to look at a local data table to give the main database it's connection values. The remote session is named but the local just uses Default as the session name. When the app connects to the server, two connections are showing per user. I've looked around the newsgroups and I understand that it is the default session showing up as well. Is there any way to stop this as the server is counting twice as many users than it should. Is there a way of stopping a default session? I tried adding another named session for the local connection and explicitly stopping that session but this didn't seem to make any difference. Can anyone point to what I'm missing? I'm using D5 & DBIsam 3.30 in this app. Thanks in advance for your help. Cheers, Mark Gibson. |
Tue, Nov 27 2007 9:00 AM | Permanent Link |
"Jose Eduardo Helminsky" | Mark
Just drop an explicit TDBISamSession component on the form, give a name and associate every dataset (TDBISamQuery and TDBISamTable) to this session (with SessionName). If you left just one dataset without session then it will create a default session. Eduardo |
Tue, Nov 27 2007 1:31 PM | Permanent Link |
Tim Young [Elevate Software] Elevate Software, Inc. timyoung@elevatesoft.com | Mark,
<< Is there a way of stopping a default session? >> As Eduardo indicated, you are connecting to the database server with the default session also, so you have to stop that in order to fix the issue. If you want to post the code that you're using for assigning the session properties, I can help you further. -- Tim Young Elevate Software www.elevatesoft.com |
Tue, Nov 27 2007 4:42 PM | Permanent Link |
Mark Gibson | Thanks guys, I'll try adding another session again. I've tried this, as I said, but it made no difference. I must have a query or table somewhere that is still using the default session.
Is there a way of determining what tables/queries are connected to the default session? Thanks again for your help. Cheers, Mark "Tim Young [Elevate Software]" <timyoung@elevatesoft.com> wrote: Mark, << Is there a way of stopping a default session? >> As Eduardo indicated, you are connecting to the database server with the default session also, so you have to stop that in order to fix the issue. If you want to post the code that you're using for assigning the session properties, I can help you further. -- Tim Young Elevate Software www.elevatesoft.com |
Tue, Nov 27 2007 5:12 PM | Permanent Link |
"Robert" | "Mark Gibson" <mail@markgibsonsoftware.com> wrote in message news:D6B27110-DBB0-4E46-B560-0B4863AF62E9@news.elevatesoft.com... > Thanks guys, I'll try adding another session again. I've tried this, as I > said, but it made no difference. I must have a query or table somewhere > that is still using the default session. Do you have more than one database? Robert |
Wed, Nov 28 2007 7:12 AM | Permanent Link |
Bruno Krayenbuhl | Is there a way of determining what tables/queries are connected to the default session?
--- WITHOUT ANY WARRANTY this can help. DBISAM 4.25 build 3, DEVELOPPER STUDIO 2006 Bruno procedure MainForm.ButtonSessionsAndDBIObjectsClick(Sender: TObject); var StringList : TStringList; lEngine: TDBISAMEngine; lSession : TDBISAMSession; lDataBase : TDBISAMDatabase; ix, ix1, ix2 : integer; lDataSet : TDBISAMDataSet; lStrActive : string; const CStrActive : array[boolean] of string = ('Inactive', 'ACTIVE'); begin if Engine <> nil then begin StringList := nil; try StringList := TStringList.Create; for ix := 0 to Engine.SessionCount - 1 do begin lSession := Engine.Sessions[ix]; StringList.Add(Format('[[SessionName=%s Version=%s]]', [lSession.Name, lSession.EngineVersion])); for ix1 := 0 to lSession.DatabaseCount - 1 do begin lDataBase := lSession.DataBases[ix1]; StringList.Add(Format('[DataBaseName=%s in %s]', [lDataBase.Name, lDataBase.Owner.Name])); for ix2 := 0 to lDataBase.DataSetCount - 1 do begin lDataSet := lDataBase.DataSets[ix2]; lStrActive := CStrActive[lDataSet.Active]; StringList.Add(Format('DataSetName=%s %s in %s', [lDataSet.Name, lStrActive, lDataSet.Owner.Name])); end; end; StringList.Add(''); end; ShowMessage(StringList.Text); finally StringList.Free; end; end; end; |
This web page was last updated on Wednesday, April 24, 2024 at 11:07 AM | Privacy PolicySite Map © 2024 Elevate Software, Inc. All Rights Reserved Questions or comments ? E-mail us at info@elevatesoft.com |