Showing posts with label file. Show all posts
Showing posts with label file. Show all posts

Tuesday, March 20, 2012

Could you tell me the VB code to check the file size in a folder and mail to xyz@abc.com automat

Dear all,

Could you tell me which code of vb scrip that i can check file size as follow ?

Dim FSO, Fyl
Set FSO = CreateObject("Scripting.FileSystemObject")
Set Fyl = CreateObject("File")

If FSO.FileExists("C:\temp\lcbseg.log") Then
Set Fyl = FSO.GetFile("C:\temp\lcbseg.log")
If Fyl.Size > 0 Then
Main = DTSStepScriptResult_ExecuteTask
Else
Main = DTSStepScriptResult_DontExecuteTask
End If
End if

Thanks

Best regards,

Kusuma

You need to do this in two stages, since there is no workflow script anymore.

Here is a sample for nthe Script Task. It uses a variable called FileSize, into which it stores the file size, surpirse!

Public Sub Main()

Dim info As System.IO.FileInfo = New System.IO.FileInfo("C:\File.txt")

Dim variables As New Variables

Dts.VariableDispenser.LockOneForWrite("FileSize", variables)

variables(0).Value = info.Length

variables.Unlock()

Dts.TaskResult = Dts.Results.Success

End Sub

Now you would use a precedenc constraint from the sript task to the next task, but be sure to include an expression. Double-click to get the UI, and try and expression like this-

@.[Use::FileSize] > 0

|||

I've tried to follow your code DarrenSQLIS, but it has the error "FileSize" for read/write access with error 0xC0010001 "The variable cannot be found. how can i fix this problem?

So i've some questions where can i declare FileSize variable. It's on SSIS menu=> varible,isn't it? and what's type of FileSize variable. For next what's property of expresstion to use @.[Use::FileSize] > 0.

Many thanks.

Best Regards,

Kusuma

|||I know you asked how do check for a file size equal to non zero in a script task, which can certainly be done with a script task as Darren illustrates.

Another technique for checking file existence and size simultaneously is use of "WMI Data Reader Task" with WQL. Use of the WMI data reader task will require a WMI connection manager, which is quick simple to configure, and available through the task's UI.

For example, the following WQL query checks for the existence and size of c:\boot.ini. simultaneously.

Select FileSize From CIM_Datafile Where Name = 'C:\\boot.ini'

After the WMI task, a downstream task can constrained by the following expression, which evaluates to true only for an existent, non zero byte file.

@.FileLength > "0\r\n"

NOTE, in this case, @.FileLength is a string variable, unlike the script task case. The reason the variable for file size is a string rather than a uint64 is that the WMI Data Reader task writes string and/or object variable types. The backslash is a special character to WMI, and as such is doubled up (escaped) in the WQL query.
|||

KUS wrote:

Dear all,

Could you tell me which code of vb scrip that i can check file size as follow ?

Dim FSO, Fyl
Set FSO = CreateObject("Scripting.FileSystemObject")
Set Fyl = CreateObject("File")

If FSO.FileExists("C:\temp\lcbseg.log") Then
Set Fyl = FSO.GetFile("C:\temp\lcbseg.log")
If Fyl.Size > 0 Then
Main = DTSStepScriptResult_ExecuteTask
Else
Main = DTSStepScriptResult_DontExecuteTask
End If
End if

Thanks

Best regards,

Kusuma

|||Hey hi . Could you tell me a VB code so that I can check a file size in a folder and mail to abc@.xyz.com if the file size is less than 10MB?|||First of all read the code above, it shows you how to get the file size into a variable. Then use an SMTP Send Mail Task to send the mail. To restrict the email to only files < 10MB, add an expression on the precendence constraint between the Script Task and Mail Task, @.Var < 10000sql

Monday, March 19, 2012

Could not restore db from the backup file. Please help!

Hi All,
I normally restore a database from a backup file as a test
db for myself on daily basis without any problems. But
somehow today, I got this kind of error if I ran the
restore task from EM:
"SqlDumpExceptionHandler: Process 52 generated fatal
exception C0000005 EXCEPTION_ACCESS_VIOLATION. SQL Server
is terminating this process".
If I ran restore sql statement from query analyzer, it
returned succeed message; however, from the EM the
restored db is marked with loading and I couldn't use it.
I digged into this problem but couldn't find any answers.
Please help
OrchidSounds like a corrupt backup (which you should expect
occasionally).
>--Original Message--
>Hi All,
>I normally restore a database from a backup file as a
test
>db for myself on daily basis without any problems. But
>somehow today, I got this kind of error if I ran the
>restore task from EM:
>"SqlDumpExceptionHandler: Process 52 generated fatal
>exception C0000005 EXCEPTION_ACCESS_VIOLATION. SQL Server
>is terminating this process".
>If I ran restore sql statement from query analyzer, it
>returned succeed message; however, from the EM the
>restored db is marked with loading and I couldn't use
it.
>I digged into this problem but couldn't find any
answers.
>Please help
>Orchid
>.
>|||How can I figure out it's a corrupt backup? and How can I
fix it? Thanks
>--Original Message--
>Sounds like a corrupt backup (which you should expect
>occasionally).
>>--Original Message--
>>Hi All,
>>I normally restore a database from a backup file as a
>test
>>db for myself on daily basis without any problems. But
>>somehow today, I got this kind of error if I ran the
>>restore task from EM:
>>"SqlDumpExceptionHandler: Process 52 generated fatal
>>exception C0000005 EXCEPTION_ACCESS_VIOLATION. SQL
Server
>>is terminating this process".
>>If I ran restore sql statement from query analyzer, it
>>returned succeed message; however, from the EM the
>>restored db is marked with loading and I couldn't use
>it.
>>I digged into this problem but couldn't find any
>answers.
>>Please help
>>Orchid
>>.
>.
>

could not read file 'snapshot.pre' due to OS error 5

Hi,
I am new to this replication thing and got bogged down on this issue.
My system consists of:
1. Publisher, SQL 2000 login xxxx password yyyy. Transactional
replication. Allow pull. On PAL, xxxx exists. Snapshot on default
folder
2. Subscriber, SQL 2005, existing on non-trusted domain, login xxxx
password yyyy. Pull replication. Read snapshot from default. Agent
process account = Subscriber\xxxx, Distributor connection = xxxx using
sql server authentication (I tried Impersonating but won't work).
Publisher can create a snapshot but Subscriber seem to have problem. I
cannot possibly add Subscriber\xxxx into PAL because it's not a
trusted domain(?). What am I doing wrong? Please help.
ben
error 5 is generic access denied. Is the snapshot folder shared? And does
the SQL Server Agent account or the account you are impersonating with have
read and list files and folders rights on the snapshot share and underlying
files and folders?
http://www.zetainteractive.com - Shift Happens!
Looking for a SQL Server replication book?
http://www.nwsu.com/0974973602.html
Looking for a FAQ on Indexing Services/SQL FTS
http://www.indexserverfaq.com
"benito" <lochinvar.geo@.gmail.com> wrote in message
news:f7d8b5fe-38d1-4073-b4d4-6f2d5023e272@.o6g2000hsd.googlegroups.com...
> Hi,
> I am new to this replication thing and got bogged down on this issue.
> My system consists of:
> 1. Publisher, SQL 2000 login xxxx password yyyy. Transactional
> replication. Allow pull. On PAL, xxxx exists. Snapshot on default
> folder
> 2. Subscriber, SQL 2005, existing on non-trusted domain, login xxxx
> password yyyy. Pull replication. Read snapshot from default. Agent
> process account = Subscriber\xxxx, Distributor connection = xxxx using
> sql server authentication (I tried Impersonating but won't work).
> Publisher can create a snapshot but Subscriber seem to have problem. I
> cannot possibly add Subscriber\xxxx into PAL because it's not a
> trusted domain(?). What am I doing wrong? Please help.
> ben
|||Thanks for your reply Hilary. I reviewed the folder rights, password,
logins to make sure they are correct and now it seems to work fine.
ben
On Dec 4, 9:23 am, "Hilary Cotter" <hilary.cot...@.gmail.com> wrote:
> error 5 is generic access denied. Is the snapshot folder shared? And does
> the SQL Server Agent account or the account you are impersonating with have
> read and list files and folders rights on the snapshot share and underlying
> files and folders?
> --http://www.zetainteractive.com- Shift Happens!
> Looking for a SQL Server replication book?http://www.nwsu.com/0974973602.html
> Looking for a FAQ on Indexing Services/SQL FTShttp://www.indexserverfaq.com"benito" <lochinvar...@.gmail.com> wrote in message
> news:f7d8b5fe-38d1-4073-b4d4-6f2d5023e272@.o6g2000hsd.googlegroups.com...
>
>
>
>
> - Show quoted text -

Could not open FCB for invalid file ID 5120

I was just running a query and got the following error.
Could not open FCB for invalid file ID 5120 in database
<dbname>. Table or database may be corrupted..
Any ideas?
Hi,
Execute the DBCC CHECKDB with REPAIR_REBUILD option. If you still have
issues then take a full database backup and you may need to try the option
REPAIR_ALLOW_DATA_LOSS with DBCC CHECKDB.
Thanks
Hari
MCDBA
<anonymous@.discussions.microsoft.com> wrote in message
news:299dc01c465ab$06520cb0$a501280a@.phx.gbl...
> I was just running a query and got the following error.
> Could not open FCB for invalid file ID 5120 in database
> <dbname>. Table or database may be corrupted..
> Any ideas?
|||I did this just before I ran the query.
I repaired all of the errors found and then ran the query.

>--Original Message--
>Hi,
>Execute the DBCC CHECKDB with REPAIR_REBUILD option. If
you still have
>issues then take a full database backup and you may need
to try the option
>REPAIR_ALLOW_DATA_LOSS with DBCC CHECKDB.
>
>--
>Thanks
>Hari
>MCDBA
><anonymous@.discussions.microsoft.com> wrote in message
>news:299dc01c465ab$06520cb0$a501280a@.phx.gbl...
>
>.
>
|||If the AUTO SHRINK is enabled on this database, then disable it.
Otherwise do not issue DBCC SHRINKFILE statement while SHRINKDATABASE is working.
Also confirm what is the level of service pack on SQL?
As there is no confirmation of version used, check whether this KBA http://support.microsoft.com/default...b;EN-US;276043 is any help.
"anonymous@.discussions.microsoft.com" wrote:

> I did this just before I ran the query.
> I repaired all of the errors found and then ran the query.
> you still have
> to try the option
>
|||Can you explain the advice below about shrinkdatabase and shrinkfile? Can
you also explain how autoshrink could cause the invalid FCB message?
Thanks.
Paul Randal
Dev Lead, Microsoft SQL Server Storage Engine
This posting is provided "AS IS" with no warranties, and confers no rights.
"SatyaSKJ" <SatyaSKJ@.discussions.microsoft.com> wrote in message
news:961E7787-C82B-44D3-8653-56D9BCFD3CC2@.microsoft.com...
> If the AUTO SHRINK is enabled on this database, then disable it.
> Otherwise do not issue DBCC SHRINKFILE statement while SHRINKDATABASE is
working.
> Also confirm what is the level of service pack on SQL?
> As there is no confirmation of version used, check whether this KBA
http://support.microsoft.com/default...b;EN-US;276043 is any help.[vbcol=seagreen]
>
> "anonymous@.discussions.microsoft.com" wrote:
|||This is very bad advice.
Microsoft does not recommend you run repair blindly without working out the
root cause of your problem and the consequences of running repair. Running
REPAIR_ALLOW_DATA_LOSS (as its name suggests) deletes data with no heed to
whatever business logic is inherent in your database. Even running
REPAIR_REBUILD without first working out what happened is very foolish and
is just a band-aid until the problem occurs again.
Regards.
Paul Randal
Dev Lead, Microsoft SQL Server Storage Engine
This posting is provided "AS IS" with no warranties, and confers no rights.
"Hari Prasad" <hari_prasad_k@.hotmail.com> wrote in message
news:uv3QnuaZEHA.1248@.TK2MSFTNGP11.phx.gbl...
> Hi,
> Execute the DBCC CHECKDB with REPAIR_REBUILD option. If you still have
> issues then take a full database backup and you may need to try the option
> REPAIR_ALLOW_DATA_LOSS with DBCC CHECKDB.
>
> --
> Thanks
> Hari
> MCDBA
> <anonymous@.discussions.microsoft.com> wrote in message
> news:299dc01c465ab$06520cb0$a501280a@.phx.gbl...
>

Could not open FCB for invalid file ID 5120

I was just running a query and got the following error.
Could not open FCB for invalid file ID 5120 in database
<dbname>. Table or database may be corrupted..
Any ideas?Hi,
Execute the DBCC CHECKDB with REPAIR_REBUILD option. If you still have
issues then take a full database backup and you may need to try the option
REPAIR_ALLOW_DATA_LOSS with DBCC CHECKDB.
Thanks
Hari
MCDBA
<anonymous@.discussions.microsoft.com> wrote in message
news:299dc01c465ab$06520cb0$a501280a@.phx
.gbl...
> I was just running a query and got the following error.
> Could not open FCB for invalid file ID 5120 in database
> <dbname>. Table or database may be corrupted..
> Any ideas?|||I did this just before I ran the query.
I repaired all of the errors found and then ran the query.

>--Original Message--
>Hi,
>Execute the DBCC CHECKDB with REPAIR_REBUILD option. If
you still have
>issues then take a full database backup and you may need
to try the option
>REPAIR_ALLOW_DATA_LOSS with DBCC CHECKDB.
>
>--
>Thanks
>Hari
>MCDBA
><anonymous@.discussions.microsoft.com> wrote in message
> news:299dc01c465ab$06520cb0$a501280a@.phx
.gbl...
>
>.
>|||Can you explain the advice below about shrinkdatabase and shrinkfile? Can
you also explain how autoshrink could cause the invalid FCB message?
Thanks.
Paul Randal
Dev Lead, Microsoft SQL Server Storage Engine
This posting is provided "AS IS" with no warranties, and confers no rights.
"SatyaSKJ" <SatyaSKJ@.discussions.microsoft.com> wrote in message
news:961E7787-C82B-44D3-8653-56D9BCFD3CC2@.microsoft.com...
> If the AUTO SHRINK is enabled on this database, then disable it.
> Otherwise do not issue DBCC SHRINKFILE statement while SHRINKDATABASE is
working.
> Also confirm what is the level of service pack on SQL?
> As there is no confirmation of version used, check whether this KBA
http://support.microsoft.com/defaul...kb;EN-US;276043 is any help.[vbcol=seagreen]
>
> "anonymous@.discussions.microsoft.com" wrote:
>|||This is very bad advice.
Microsoft does not recommend you run repair blindly without working out the
root cause of your problem and the consequences of running repair. Running
REPAIR_ALLOW_DATA_LOSS (as its name suggests) deletes data with no heed to
whatever business logic is inherent in your database. Even running
REPAIR_REBUILD without first working out what happened is very foolish and
is just a band-aid until the problem occurs again.
Regards.
Paul Randal
Dev Lead, Microsoft SQL Server Storage Engine
This posting is provided "AS IS" with no warranties, and confers no rights.
"Hari Prasad" <hari_prasad_k@.hotmail.com> wrote in message
news:uv3QnuaZEHA.1248@.TK2MSFTNGP11.phx.gbl...
> Hi,
> Execute the DBCC CHECKDB with REPAIR_REBUILD option. If you still have
> issues then take a full database backup and you may need to try the option
> REPAIR_ALLOW_DATA_LOSS with DBCC CHECKDB.
>
> --
> Thanks
> Hari
> MCDBA
> <anonymous@.discussions.microsoft.com> wrote in message
> news:299dc01c465ab$06520cb0$a501280a@.phx
.gbl...
>

Could not open FCB for invalid file ID 5120

I was just running a query and got the following error.
Could not open FCB for invalid file ID 5120 in database
<dbname>. Table or database may be corrupted..
Any ideas?Hi,
Execute the DBCC CHECKDB with REPAIR_REBUILD option. If you still have
issues then take a full database backup and you may need to try the option
REPAIR_ALLOW_DATA_LOSS with DBCC CHECKDB.
Thanks
Hari
MCDBA
<anonymous@.discussions.microsoft.com> wrote in message
news:299dc01c465ab$06520cb0$a501280a@.phx.gbl...
> I was just running a query and got the following error.
> Could not open FCB for invalid file ID 5120 in database
> <dbname>. Table or database may be corrupted..
> Any ideas?|||I did this just before I ran the query.
I repaired all of the errors found and then ran the query.
>--Original Message--
>Hi,
>Execute the DBCC CHECKDB with REPAIR_REBUILD option. If
you still have
>issues then take a full database backup and you may need
to try the option
>REPAIR_ALLOW_DATA_LOSS with DBCC CHECKDB.
>
>--
>Thanks
>Hari
>MCDBA
><anonymous@.discussions.microsoft.com> wrote in message
>news:299dc01c465ab$06520cb0$a501280a@.phx.gbl...
>> I was just running a query and got the following error.
>> Could not open FCB for invalid file ID 5120 in database
>> <dbname>. Table or database may be corrupted..
>> Any ideas?
>
>.
>|||If the AUTO SHRINK is enabled on this database, then disable it.
Otherwise do not issue DBCC SHRINKFILE statement while SHRINKDATABASE is working.
Also confirm what is the level of service pack on SQL?
As there is no confirmation of version used, check whether this KBA http://support.microsoft.com/default.aspx?scid=kb;EN-US;276043 is any help.
"anonymous@.discussions.microsoft.com" wrote:
> I did this just before I ran the query.
> I repaired all of the errors found and then ran the query.
> >--Original Message--
> >Hi,
> >
> >Execute the DBCC CHECKDB with REPAIR_REBUILD option. If
> you still have
> >issues then take a full database backup and you may need
> to try the option
> >REPAIR_ALLOW_DATA_LOSS with DBCC CHECKDB.
> >
> >
> >--
> >Thanks
> >Hari
> >MCDBA
> ><anonymous@.discussions.microsoft.com> wrote in message
> >news:299dc01c465ab$06520cb0$a501280a@.phx.gbl...
> >> I was just running a query and got the following error.
> >>
> >> Could not open FCB for invalid file ID 5120 in database
> >> <dbname>. Table or database may be corrupted..
> >>
> >> Any ideas?
> >
> >
> >.
> >
>|||Can you explain the advice below about shrinkdatabase and shrinkfile? Can
you also explain how autoshrink could cause the invalid FCB message?
Thanks.
--
Paul Randal
Dev Lead, Microsoft SQL Server Storage Engine
This posting is provided "AS IS" with no warranties, and confers no rights.
"SatyaSKJ" <SatyaSKJ@.discussions.microsoft.com> wrote in message
news:961E7787-C82B-44D3-8653-56D9BCFD3CC2@.microsoft.com...
> If the AUTO SHRINK is enabled on this database, then disable it.
> Otherwise do not issue DBCC SHRINKFILE statement while SHRINKDATABASE is
working.
> Also confirm what is the level of service pack on SQL?
> As there is no confirmation of version used, check whether this KBA
http://support.microsoft.com/default.aspx?scid=kb;EN-US;276043 is any help.
>
> "anonymous@.discussions.microsoft.com" wrote:
> > I did this just before I ran the query.
> > I repaired all of the errors found and then ran the query.
> >
> > >--Original Message--
> > >Hi,
> > >
> > >Execute the DBCC CHECKDB with REPAIR_REBUILD option. If
> > you still have
> > >issues then take a full database backup and you may need
> > to try the option
> > >REPAIR_ALLOW_DATA_LOSS with DBCC CHECKDB.
> > >
> > >
> > >--
> > >Thanks
> > >Hari
> > >MCDBA
> > ><anonymous@.discussions.microsoft.com> wrote in message
> > >news:299dc01c465ab$06520cb0$a501280a@.phx.gbl...
> > >> I was just running a query and got the following error.
> > >>
> > >> Could not open FCB for invalid file ID 5120 in database
> > >> <dbname>. Table or database may be corrupted..
> > >>
> > >> Any ideas?
> > >
> > >
> > >.
> > >
> >|||This is very bad advice.
Microsoft does not recommend you run repair blindly without working out the
root cause of your problem and the consequences of running repair. Running
REPAIR_ALLOW_DATA_LOSS (as its name suggests) deletes data with no heed to
whatever business logic is inherent in your database. Even running
REPAIR_REBUILD without first working out what happened is very foolish and
is just a band-aid until the problem occurs again.
Regards.
--
Paul Randal
Dev Lead, Microsoft SQL Server Storage Engine
This posting is provided "AS IS" with no warranties, and confers no rights.
"Hari Prasad" <hari_prasad_k@.hotmail.com> wrote in message
news:uv3QnuaZEHA.1248@.TK2MSFTNGP11.phx.gbl...
> Hi,
> Execute the DBCC CHECKDB with REPAIR_REBUILD option. If you still have
> issues then take a full database backup and you may need to try the option
> REPAIR_ALLOW_DATA_LOSS with DBCC CHECKDB.
>
> --
> Thanks
> Hari
> MCDBA
> <anonymous@.discussions.microsoft.com> wrote in message
> news:299dc01c465ab$06520cb0$a501280a@.phx.gbl...
> > I was just running a query and got the following error.
> >
> > Could not open FCB for invalid file ID 5120 in database
> > <dbname>. Table or database may be corrupted..
> >
> > Any ideas?
>

Could not open FCB for invalid file ID 46336 in database 'Production'..

For about two hours last evening our database started producing these errors
and various jobs failed.
This morning all seems quiet. However we do rebuild our indexes overnight.
Should we worry about this?
The jobs that failed do not process any text columns (the only mention I
found on microsofts site).
The File ID cannot relate to sysfiles. Does anyone know what is does relate
to?
SQL Server 2000 SP3A.
Hi,
Please run DBCC checktable to see if there are any corruption related errors on this table. Take full database backup before you execute dbcc checktable.
If the output come clear then you do not want to worry any more.
Thanks
Hari
MCDBA
-- Paul Cahill wrote: --
For about two hours last evening our database started producing these errors
and various jobs failed.
This morning all seems quiet. However we do rebuild our indexes overnight.
Should we worry about this?
The jobs that failed do not process any text columns (the only mention I
found on microsofts site).
The File ID cannot relate to sysfiles. Does anyone know what is does relate
to?
SQL Server 2000 SP3A.
|||Thanks Hari
How do I tell which table. I tried offering up the number above as an ID to
sysobjects but nothing came back.
Paul
"Hari" <hari_prasad_k@.hotmail.com> wrote in message
news:F3226200-D6DC-4939-8773-4E5CFC0FA567@.microsoft.com...
> Hi,
> Please run DBCC checktable to see if there are any corruption related
errors on this table. Take full database backup before you execute dbcc
checktable.
> If the output come clear then you do not want to worry any more.
> Thanks
> Hari
> MCDBA
>
> -- Paul Cahill wrote: --
> For about two hours last evening our database started producing these
errors
> and various jobs failed.
> This morning all seems quiet. However we do rebuild our indexes
overnight.
> Should we worry about this?
> The jobs that failed do not process any text columns (the only
mention I
> found on microsofts site).
> The File ID cannot relate to sysfiles. Does anyone know what is does
relate
> to?
> SQL Server 2000 SP3A.
>
>
|||Hi,
I feel that it should be a problem with tempdb. If it is the case no issues.
Anyway can you execute DBCC CHECKDB('dbname') for that database and ensure
no errors.
Thanks
Hari
MCDBA
"Paul Cahill" <XYZpaul.cahillXYZ@.blueyonder.co.uk> wrote in message
news:O0Ga6aBNEHA.2844@.tk2msftngp13.phx.gbl...
> Thanks Hari
> How do I tell which table. I tried offering up the number above as an ID
to[vbcol=seagreen]
> sysobjects but nothing came back.
> Paul
>
> "Hari" <hari_prasad_k@.hotmail.com> wrote in message
> news:F3226200-D6DC-4939-8773-4E5CFC0FA567@.microsoft.com...
> errors on this table. Take full database backup before you execute dbcc
> checktable.
these[vbcol=seagreen]
> errors
> overnight.
> mention I
does
> relate
>
|||I was starting to suspect as much.
Let's just assume this never happened
Paul
"Hari" <hari_prasad_k@.hotmail.com> wrote in message
news:Oom$kfBNEHA.3420@.TK2MSFTNGP11.phx.gbl...
> Hi,
> I feel that it should be a problem with tempdb. If it is the case no
issues.
> Anyway can you execute DBCC CHECKDB('dbname') for that database and ensure
> no errors.
> Thanks
> Hari
> MCDBA
>
> "Paul Cahill" <XYZpaul.cahillXYZ@.blueyonder.co.uk> wrote in message
> news:O0Ga6aBNEHA.2844@.tk2msftngp13.phx.gbl...
> to
> these
> does
>

Could not open FCB for invalid file ID 46336 in database 'Production'..

For about two hours last evening our database started producing these errors
and various jobs failed.
This morning all seems quiet. However we do rebuild our indexes overnight.
Should we worry about this?
The jobs that failed do not process any text columns (the only mention I
found on microsofts site).
The File ID cannot relate to sysfiles. Does anyone know what is does relate
to?
SQL Server 2000 SP3A.Hi
Please run DBCC checktable to see if there are any corruption related errors on this table. Take full database backup before you execute dbcc checktable.
If the output come clear then you do not want to worry any more
Thank
Har
MCDB
-- Paul Cahill wrote: --
For about two hours last evening our database started producing these error
and various jobs failed
This morning all seems quiet. However we do rebuild our indexes overnight
Should we worry about this
The jobs that failed do not process any text columns (the only mention
found on microsofts site)
The File ID cannot relate to sysfiles. Does anyone know what is does relat
to
SQL Server 2000 SP3A|||Thanks Hari
How do I tell which table. I tried offering up the number above as an ID to
sysobjects but nothing came back.
Paul
"Hari" <hari_prasad_k@.hotmail.com> wrote in message
news:F3226200-D6DC-4939-8773-4E5CFC0FA567@.microsoft.com...
> Hi,
> Please run DBCC checktable to see if there are any corruption related
errors on this table. Take full database backup before you execute dbcc
checktable.
> If the output come clear then you do not want to worry any more.
> Thanks
> Hari
> MCDBA
>
> -- Paul Cahill wrote: --
> For about two hours last evening our database started producing these
errors
> and various jobs failed.
> This morning all seems quiet. However we do rebuild our indexes
overnight.
> Should we worry about this?
> The jobs that failed do not process any text columns (the only
mention I
> found on microsofts site).
> The File ID cannot relate to sysfiles. Does anyone know what is does
relate
> to?
> SQL Server 2000 SP3A.
>
>|||Hi,
I feel that it should be a problem with tempdb. If it is the case no issues.
Anyway can you execute DBCC CHECKDB('dbname') for that database and ensure
no errors.
Thanks
Hari
MCDBA
"Paul Cahill" <XYZpaul.cahillXYZ@.blueyonder.co.uk> wrote in message
news:O0Ga6aBNEHA.2844@.tk2msftngp13.phx.gbl...
> Thanks Hari
> How do I tell which table. I tried offering up the number above as an ID
to
> sysobjects but nothing came back.
> Paul
>
> "Hari" <hari_prasad_k@.hotmail.com> wrote in message
> news:F3226200-D6DC-4939-8773-4E5CFC0FA567@.microsoft.com...
> > Hi,
> >
> > Please run DBCC checktable to see if there are any corruption related
> errors on this table. Take full database backup before you execute dbcc
> checktable.
> > If the output come clear then you do not want to worry any more.
> >
> > Thanks
> > Hari
> > MCDBA
> >
> >
> > -- Paul Cahill wrote: --
> >
> > For about two hours last evening our database started producing
these
> errors
> > and various jobs failed.
> > This morning all seems quiet. However we do rebuild our indexes
> overnight.
> > Should we worry about this?
> >
> > The jobs that failed do not process any text columns (the only
> mention I
> > found on microsofts site).
> >
> > The File ID cannot relate to sysfiles. Does anyone know what is
does
> relate
> > to?
> >
> > SQL Server 2000 SP3A.
> >
> >
> >
>|||I was starting to suspect as much.
Let's just assume this never happened :)
Paul
"Hari" <hari_prasad_k@.hotmail.com> wrote in message
news:Oom$kfBNEHA.3420@.TK2MSFTNGP11.phx.gbl...
> Hi,
> I feel that it should be a problem with tempdb. If it is the case no
issues.
> Anyway can you execute DBCC CHECKDB('dbname') for that database and ensure
> no errors.
> Thanks
> Hari
> MCDBA
>
> "Paul Cahill" <XYZpaul.cahillXYZ@.blueyonder.co.uk> wrote in message
> news:O0Ga6aBNEHA.2844@.tk2msftngp13.phx.gbl...
> > Thanks Hari
> >
> > How do I tell which table. I tried offering up the number above as an ID
> to
> > sysobjects but nothing came back.
> >
> > Paul
> >
> >
> >
> > "Hari" <hari_prasad_k@.hotmail.com> wrote in message
> > news:F3226200-D6DC-4939-8773-4E5CFC0FA567@.microsoft.com...
> > > Hi,
> > >
> > > Please run DBCC checktable to see if there are any corruption related
> > errors on this table. Take full database backup before you execute dbcc
> > checktable.
> > > If the output come clear then you do not want to worry any more.
> > >
> > > Thanks
> > > Hari
> > > MCDBA
> > >
> > >
> > > -- Paul Cahill wrote: --
> > >
> > > For about two hours last evening our database started producing
> these
> > errors
> > > and various jobs failed.
> > > This morning all seems quiet. However we do rebuild our indexes
> > overnight.
> > > Should we worry about this?
> > >
> > > The jobs that failed do not process any text columns (the only
> > mention I
> > > found on microsofts site).
> > >
> > > The File ID cannot relate to sysfiles. Does anyone know what is
> does
> > relate
> > > to?
> > >
> > > SQL Server 2000 SP3A.
> > >
> > >
> > >
> >
> >
>

Could not open FCB for invalid file ID 46336 in database 'Production'..

For about two hours last evening our database started producing these errors
and various jobs failed.
This morning all seems quiet. However we do rebuild our indexes overnight.
Should we worry about this?
The jobs that failed do not process any text columns (the only mention I
found on microsofts site).
The File ID cannot relate to sysfiles. Does anyone know what is does relate
to?
SQL Server 2000 SP3A.Hi,
Please run DBCC checktable to see if there are any corruption related errors
on this table. Take full database backup before you execute dbcc checktable
.
If the output come clear then you do not want to worry any more.
Thanks
Hari
MCDBA
-- Paul Cahill wrote: --
For about two hours last evening our database started producing these errors
and various jobs failed.
This morning all seems quiet. However we do rebuild our indexes overnight.
Should we worry about this?
The jobs that failed do not process any text columns (the only mention I
found on microsofts site).
The File ID cannot relate to sysfiles. Does anyone know what is does relate
to?
SQL Server 2000 SP3A.|||Thanks Hari
How do I tell which table. I tried offering up the number above as an ID to
sysobjects but nothing came back.
Paul
"Hari" <hari_prasad_k@.hotmail.com> wrote in message
news:F3226200-D6DC-4939-8773-4E5CFC0FA567@.microsoft.com...
> Hi,
> Please run DBCC checktable to see if there are any corruption related
errors on this table. Take full database backup before you execute dbcc
checktable.
> If the output come clear then you do not want to worry any more.
> Thanks
> Hari
> MCDBA
>
> -- Paul Cahill wrote: --
> For about two hours last evening our database started producing these
errors
> and various jobs failed.
> This morning all seems quiet. However we do rebuild our indexes
overnight.
> Should we worry about this?
> The jobs that failed do not process any text columns (the only
mention I
> found on microsofts site).
> The File ID cannot relate to sysfiles. Does anyone know what is does
relate
> to?
> SQL Server 2000 SP3A.
>
>|||Hi,
I feel that it should be a problem with tempdb. If it is the case no issues.
Anyway can you execute DBCC CHECKDB('dbname') for that database and ensure
no errors.
Thanks
Hari
MCDBA
"Paul Cahill" <XYZpaul.cahillXYZ@.blueyonder.co.uk> wrote in message
news:O0Ga6aBNEHA.2844@.tk2msftngp13.phx.gbl...
> Thanks Hari
> How do I tell which table. I tried offering up the number above as an ID
to
> sysobjects but nothing came back.
> Paul
>
> "Hari" <hari_prasad_k@.hotmail.com> wrote in message
> news:F3226200-D6DC-4939-8773-4E5CFC0FA567@.microsoft.com...
> errors on this table. Take full database backup before you execute dbcc
> checktable.
these[vbcol=seagreen]
> errors
> overnight.
> mention I
does[vbcol=seagreen]
> relate
>|||I was starting to suspect as much.
Let's just assume this never happened
Paul
"Hari" <hari_prasad_k@.hotmail.com> wrote in message
news:Oom$kfBNEHA.3420@.TK2MSFTNGP11.phx.gbl...
> Hi,
> I feel that it should be a problem with tempdb. If it is the case no
issues.
> Anyway can you execute DBCC CHECKDB('dbname') for that database and ensure
> no errors.
> Thanks
> Hari
> MCDBA
>
> "Paul Cahill" <XYZpaul.cahillXYZ@.blueyonder.co.uk> wrote in message
> news:O0Ga6aBNEHA.2844@.tk2msftngp13.phx.gbl...
> to
> these
> does
>

Could not open FCB for invalid file ID 3 in database

Hi there,

I have a software package that uses SQL server for the database. When loading a large amount of data I receive this error message. Can you please give me some idea what may be causing this error.

********* Memory Status *********
Free physical memory(KB) = 519528
Total of physical memory(KB) = 2147000
User Total of virtual address space(KB) = 2147352
Free virtual user(KB) = 2110500
Percent of Free physical = 0.241979
Percent of Free Virtual space = 0.982838
FIRecordset::GetNewConnection : DBException (Could not open FCB for invalid file ID 3 in database 'finance'.

Thanks in advance!!

SteveApply SP3a. It's a documented error which was fixed in SP3a patch. If you already have SP3a, reapply it and look thru all error logs in \install directory to see if there's any errors.

Could not open FCB for invalid file ID 20294 in database

Hi,
I am getting this error when I am trying to delete record
"Server: Msg 5180, Level 22, State 1, Line 1
Could not open FCB for invalid file ID 20294 in database 'SAS_Test'.
Connection Broken"
But when I use select command it works fine. I can ping the server, but some
how can't delete does not work!.
I check the SQL server log and it has "Could not open FCB for invalid file
ID 20294 in database, Error: 5180, Severity: 22, State: 1"
Any help would be appreciated.
Shan
Run DBCC CheckDB for that database to check physical corruption under file..
also refer to this link: -
http://support.microsoft.com/default...;en-us;Q276043
"Shan" wrote:

> Hi,
> I am getting this error when I am trying to delete record
> "Server: Msg 5180, Level 22, State 1, Line 1
> Could not open FCB for invalid file ID 20294 in database 'SAS_Test'.
> Connection Broken"
> But when I use select command it works fine. I can ping the server, but some
> how can't delete does not work!.
> I check the SQL server log and it has "Could not open FCB for invalid file
> ID 20294 in database, Error: 5180, Severity: 22, State: 1"
> Any help would be appreciated.
> --
> Shan

Could not open FCB for invalid file ID 20294 in database

Hi,
I am getting this error when I am trying to delete record
"Server: Msg 5180, Level 22, State 1, Line 1
Could not open FCB for invalid file ID 20294 in database 'SAS_Test'.
Connection Broken"
But when I use select command it works fine. I can ping the server, but some
how can't delete does not work!.
I check the SQL server log and it has "Could not open FCB for invalid file
ID 20294 in database, Error: 5180, Severity: 22, State: 1"
Any help would be appreciated.
--
ShanRun DBCC CheckDB for that database to check physical corruption under file..
also refer to this link: -
http://support.microsoft.com/defaul...b;en-us;Q276043
"Shan" wrote:

> Hi,
> I am getting this error when I am trying to delete record
> "Server: Msg 5180, Level 22, State 1, Line 1
> Could not open FCB for invalid file ID 20294 in database 'SAS_Test'.
> Connection Broken"
> But when I use select command it works fine. I can ping the server, but so
me
> how can't delete does not work!.
> I check the SQL server log and it has "Could not open FCB for invalid file
> ID 20294 in database, Error: 5180, Severity: 22, State: 1"
> Any help would be appreciated.
> --
> Shan

Could not open FCB for invalid file ID 20294 in database

Hi,
I am getting this error when I am trying to delete record
"Server: Msg 5180, Level 22, State 1, Line 1
Could not open FCB for invalid file ID 20294 in database 'SAS_Test'.
Connection Broken"
But when I use select command it works fine. I can ping the server, but some
how can't delete does not work!.
I check the SQL server log and it has "Could not open FCB for invalid file
ID 20294 in database, Error: 5180, Severity: 22, State: 1"
Any help would be appreciated.
--
ShanRun DBCC CheckDB for that database to check physical corruption under file..
also refer to this link: -
http://support.microsoft.com/default.aspx?scid=kb;en-us;Q276043
"Shan" wrote:
> Hi,
> I am getting this error when I am trying to delete record
> "Server: Msg 5180, Level 22, State 1, Line 1
> Could not open FCB for invalid file ID 20294 in database 'SAS_Test'.
> Connection Broken"
> But when I use select command it works fine. I can ping the server, but some
> how can't delete does not work!.
> I check the SQL server log and it has "Could not open FCB for invalid file
> ID 20294 in database, Error: 5180, Severity: 22, State: 1"
> Any help would be appreciated.
> --
> Shan

'Could not open FCB for invalid file ID % in database %'

Hello,
I am having some problems with my server. Installed is sql
server 7 and i have recently been getting the above error
message. I was advised to run the patch sql70sp4.exe and i
would be doing that tonight. Would this solve the problem.
Has anyone gone through this before ?
Any help appreciated.
Thanks
Chris Kentebe
ckentebe@.yahoo.ca
Hello Christopher
This message could be caused due to lot of reasons. I would advise you to
open a case with PSS to work on this in more detail.
Thank you for using Microsoft newsgroups.
Sincerely
Pankaj Agarwal
Microsoft Corporation
This posting is provided AS IS with no warranties, and confers no rights.

'Could not open FCB for invalid file ID % in database %'

Hello,
I am having some problems with my server. Installed is sql
server 7 and i have recently been getting the above error
message. I was advised to run the patch sql70sp4.exe and i
would be doing that tonight. Would this solve the problem.
Has anyone gone through this before ?
Any help appreciated.
Thanks
Chris Kentebe
ckentebe@.yahoo.caHello Christopher
This message could be caused due to lot of reasons. I would advise you to
open a case with PSS to work on this in more detail.
Thank you for using Microsoft newsgroups.
Sincerely
Pankaj Agarwal
Microsoft Corporation
This posting is provided AS IS with no warranties, and confers no rights.

'Could not open FCB for invalid file ID % in database %'

Hello,
I am having some problems with my server. Installed is sql
server 7 and i have recently been getting the above error
message. I was advised to run the patch sql70sp4.exe and i
would be doing that tonight. Would this solve the problem.
Has anyone gone through this before ?
Any help appreciated.
Thanks
Chris Kentebe
ckentebe@.yahoo.caHello Christopher
This message could be caused due to lot of reasons. I would advise you to
open a case with PSS to work on this in more detail.
Thank you for using Microsoft newsgroups.
Sincerely
Pankaj Agarwal
Microsoft Corporation
This posting is provided AS IS with no warranties, and confers no rights.

Could not open FCB for invalid file ID

We've been getting the following error this week on our SQL Server 2000
sp3 box:
Error: 5180, Severity: 22, State: 1
Could not open FCB for invalid file ID 0 in database 'database_name'
I've found a couple of articles relating to text and image columns may
be the cause of this, however the databases we recieved this error in
do not have text or image columns. We have gotten this error twice
over the past week, in two seperate databases on the same server. I
ran DBCC CHECKDB, and both databases passed.
Does anyone have anymore information on this error?
Hi
Check that Anti-Virus does not scan these files.
Regards
Mike
"dosberg@.yahoo.com" wrote:

> We've been getting the following error this week on our SQL Server 2000
> sp3 box:
> Error: 5180, Severity: 22, State: 1
> Could not open FCB for invalid file ID 0 in database 'database_name'
> I've found a couple of articles relating to text and image columns may
> be the cause of this, however the databases we recieved this error in
> do not have text or image columns. We have gotten this error twice
> over the past week, in two seperate databases on the same server. I
> ran DBCC CHECKDB, and both databases passed.
> Does anyone have anymore information on this error?
>

Could not open FCB for invalid file ID

We've been getting the following error this week on our SQL Server 2000
sp3 box:
Error: 5180, Severity: 22, State: 1
Could not open FCB for invalid file ID 0 in database 'database_name'
I've found a couple of articles relating to text and image columns may
be the cause of this, however the databases we recieved this error in
do not have text or image columns. We have gotten this error twice
over the past week, in two seperate databases on the same server. I
ran DBCC CHECKDB, and both databases passed.
Does anyone have anymore information on this error?Hi
Check that Anti-Virus does not scan these files.
Regards
Mike
"dosberg@.yahoo.com" wrote:

> We've been getting the following error this week on our SQL Server 2000
> sp3 box:
> Error: 5180, Severity: 22, State: 1
> Could not open FCB for invalid file ID 0 in database 'database_name'
> I've found a couple of articles relating to text and image columns may
> be the cause of this, however the databases we recieved this error in
> do not have text or image columns. We have gotten this error twice
> over the past week, in two seperate databases on the same server. I
> ran DBCC CHECKDB, and both databases passed.
> Does anyone have anymore information on this error?
>

Could not open FCB for invalid file ID

We've been getting the following error this week on our SQL Server 2000
sp3 box:
Error: 5180, Severity: 22, State: 1
Could not open FCB for invalid file ID 0 in database 'database_name'
I've found a couple of articles relating to text and image columns may
be the cause of this, however the databases we recieved this error in
do not have text or image columns. We have gotten this error twice
over the past week, in two seperate databases on the same server. I
ran DBCC CHECKDB, and both databases passed.
Does anyone have anymore information on this error?Hi
Check that Anti-Virus does not scan these files.
Regards
Mike
"dosberg@.yahoo.com" wrote:
> We've been getting the following error this week on our SQL Server 2000
> sp3 box:
> Error: 5180, Severity: 22, State: 1
> Could not open FCB for invalid file ID 0 in database 'database_name'
> I've found a couple of articles relating to text and image columns may
> be the cause of this, however the databases we recieved this error in
> do not have text or image columns. We have gotten this error twice
> over the past week, in two seperate databases on the same server. I
> ran DBCC CHECKDB, and both databases passed.
> Does anyone have anymore information on this error?
>

Could not open a connection to SQL server error on Vista

Hey,

After install Visual Studio 2005 (with SQL sever express) on recent Vista build, trying to connect to a local sse database file from Data Source Window (accessible from Data/Show data source window) gives this error:


Microsoft Visual Studio

An error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections. (provider: Named Pipes Provider, error: 40 - Could not open a connection to SQL Server)

OK

No issues if we install Visual Studio 2005 on WinXP or W2k3.

Is there any configuration we need to set on vista to allow sql connection?

Thanks,

Mei

Not having tried Vista I don't know if there are special issues there, but by default SQL Server instances are installed with the external interfaces disabled. Use SQL Server Configuration Manager to enable the protocols (if they are not enabled already). This can also be done with the SQL Server Surface Area Configuration tool.

If this does not help, see my blog (www.betav.com\blog\billva)

|||

You will have to enable SQLBrowser service.

See more details here:

http://blogs.msdn.com/sqlexpress/archive/2005/05/05/415084.aspx

|||

I have the same problem. If you have found a solution to the problem, then let me know.

Kindly

Peer Larsen, DK