468,249 Members | 1,496 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 468,249 developers. It's quick & easy.

temporary work files showing up in getoldDbSchemaTable call

Any help would be appreciated:

I have a routine on an asp.net web page, This code below point to a text
box called lbtable.

public void GetTables( )
{
//string [] TblDName = new string[255];
//string [] TblDType = new string[255];

try
{
this.Conn2 = new System.Data.OleDb.OleDbConnection();
this.Conn2.ConnectionString = curdbstring;
this.Conn2.Open();
tblNames = this.Conn2.GetOleDbSchemaTable(OleDbSchemaGuid.Tab les,
new object[] {null, null, null, "TABLE"});
this.lbtable.DataSource = null;
this.lbtable.Items.Clear();
this.lbtable.DataSource= tblNames;
this.lbtable.DataTextField = "TABLE_NAME";
this.lbtable.DataBind();

}
catch (OleDbException ex)
{
Trace.Write(ex.Message);
}
finally
{
this.Conn2.Close();
}
return;
}

and most of the time it works correctly. However sometimes it show all the
correct tables and some tables up to 4 that start with ~TMPCLP. I
checked the access database and the files do not show up when viewing the
database in access(Access XP). When I refresh the screen, the bad files
still show, however I can not delete these files. If I shut everything down
and reboot, the bad files disappear and may not reappear for a few days.

Thanks in advance for your help

Sincerely
Brian O'Haire
Nov 15 '05 #1
2 1391
Hi,

I guess it shows you temporary tables.
As a workaround you might use a DataView on result table and filter for
tables that don't start with ~.
Substring(table_name, 1, 1) <> "~" or something like that (I didn't test it
though).

--
Miha Markic - RightHand .NET consulting & development
miha at rthand com
www.rthand.com

"Brian O'Haire" <ge************@cdpswat.com> wrote in message
news:OJ**************@TK2MSFTNGP11.phx.gbl...
Any help would be appreciated:

I have a routine on an asp.net web page, This code below point to a text
box called lbtable.

public void GetTables( )
{
//string [] TblDName = new string[255];
//string [] TblDType = new string[255];

try
{
this.Conn2 = new System.Data.OleDb.OleDbConnection();
this.Conn2.ConnectionString = curdbstring;
this.Conn2.Open();
tblNames = this.Conn2.GetOleDbSchemaTable(OleDbSchemaGuid.Tab les,
new object[] {null, null, null, "TABLE"});
this.lbtable.DataSource = null;
this.lbtable.Items.Clear();
this.lbtable.DataSource= tblNames;
this.lbtable.DataTextField = "TABLE_NAME";
this.lbtable.DataBind();

}
catch (OleDbException ex)
{
Trace.Write(ex.Message);
}
finally
{
this.Conn2.Close();
}
return;
}

and most of the time it works correctly. However sometimes it show all the correct tables and some tables up to 4 that start with ~TMPCLP. I
checked the access database and the files do not show up when viewing the
database in access(Access XP). When I refresh the screen, the bad files
still show, however I can not delete these files. If I shut everything down and reboot, the bad files disappear and may not reappear for a few days.

Thanks in advance for your help

Sincerely
Brian O'Haire

Nov 15 '05 #2
Miha

Thanks for the suggestion. I agree that I am picking up the temporary files
however the part that concerned me was that I would check the database with
Access and they did not exist and then refresh the text box from the
database and get the same temporary files. Even though there was no reason
to have temporary files opened. I am the only user of the database. When I
repeated the same procedure sometimes they would show and sometimes they
would not.

Sincerely

Brian O'Haire MCSE MCDBA
and student trying to learn C# and asp.net
"Miha Markic" <miha at rthand com> wrote in message
news:u2**************@TK2MSFTNGP11.phx.gbl...
Hi,

I guess it shows you temporary tables.
As a workaround you might use a DataView on result table and filter for
tables that don't start with ~.
Substring(table_name, 1, 1) <> "~" or something like that (I didn't test it though).

--
Miha Markic - RightHand .NET consulting & development
miha at rthand com
www.rthand.com

"Brian O'Haire" <ge************@cdpswat.com> wrote in message
news:OJ**************@TK2MSFTNGP11.phx.gbl...
Any help would be appreciated:

I have a routine on an asp.net web page, This code below point to a text box called lbtable.

public void GetTables( )
{
//string [] TblDName = new string[255];
//string [] TblDType = new string[255];

try
{
this.Conn2 = new System.Data.OleDb.OleDbConnection();
this.Conn2.ConnectionString = curdbstring;
this.Conn2.Open();
tblNames = this.Conn2.GetOleDbSchemaTable(OleDbSchemaGuid.Tab les,
new object[] {null, null, null, "TABLE"});
this.lbtable.DataSource = null;
this.lbtable.Items.Clear();
this.lbtable.DataSource= tblNames;
this.lbtable.DataTextField = "TABLE_NAME";
this.lbtable.DataBind();

}
catch (OleDbException ex)
{
Trace.Write(ex.Message);
}
finally
{
this.Conn2.Close();
}
return;
}

and most of the time it works correctly. However sometimes it show all

the
correct tables and some tables up to 4 that start with ~TMPCLP. I
checked the access database and the files do not show up when viewing the database in access(Access XP). When I refresh the screen, the bad files
still show, however I can not delete these files. If I shut everything

down
and reboot, the bad files disappear and may not reappear for a few days.

Thanks in advance for your help

Sincerely
Brian O'Haire


Nov 15 '05 #3

This discussion thread is closed

Replies have been disabled for this discussion.

By using this site, you agree to our Privacy Policy and Terms of Use.