Showing posts with label run. Show all posts
Showing posts with label run. Show all posts

Friday, March 30, 2012

Invoking ms access from a scheduled job in sql server 2000

Is it possible to run a mdb from a scheduled job in sql server? I simply want to run a mdb with a autoexec in it. Don't want to use microsoft scheduler....

Thanks!

To 'run a mdb...with a autoexec in it' requires a client application.

SQL Server is NOT a client application.

Invoking or sending SQL queries using dOS

Hello Folks,
I want to create a simple batch DOS script to query mi SQL Server 2000 database. How I could do this?
I just want to run a select for a table but I dont want people to interct with sql query analyzer or enterprise manager to avoid any issues.
Regards,Look up OSQL or ISQL in Books Online.

Basically:
OSQL -S <name of your server/instance> -U <UID> -P <PWD> -d <Database to use> -Q"<your select statment>" -n -b

I do this all the time so post back if you have more questions.|||Originally posted by Paul Young
Look up OSQL or ISQL in Books Online.

Basically:
OSQL -S <name of your server/instance> -U <UID> -P <PWD> -d <Database to use> -Q"<your select statment>" -n -b

I do this all the time so post back if you have more questions.

UID stands for? PWD I assume is the pasword, isnt.

How I can redirect the results to a txt file,

OSQL -S OSQL -S <name of your server/instance> -U <UID> -P <PWD> -d <Database to use> -Q"<your select statment>" -n -b >> query.txt

Am I right?

Thanks for your prompt reply and help|||UID = User ID

You could pipe the output to a text file but the -o parm would be more usefull.|||How I can get the instance name. I have tested in my environment and I got the next error:

[DBNETLIB] Sql Server does not exist or access denied
[DBNETLIB] ConnectionOpen <Connect(())

As per this result I checked the server name I used typing osql -L. I got the names and used them but with the same result.

When I open the Sql query analyzer I connect using windows authentication option to connect to my databases.

Please suggest..|||For Windows Security I think you need to use -E option instead of -U and -P options.

Tim Ssql

Invokation of a stored procedure from an Integration Services package

Is it possible to execute a stored procedure from an Integration Services package? I see that its possible to enter sql commands that can be run but when a command to execute a stored procedure is entered the system cannot find the stored procedure (eventhough 'use mydbname' preceded it.

thx,

Marilyn

You certainly can execute a stored procedure, but we'll need some more information to help.

Are you using the Execute SQL task in SSIS? Is the database SQL Server? Does the account your are developing under have permissions to see the stored procedure? What error messages are you seeing?

Donald

Invisible Replications

Derek,
can you run sp_removedbreplication in the previously
published databases.
If this doesn't remove the rogue red x's in replication
monitor, try restarting the sql server service - when I
have investigated this before, there is a reference to a
temp table in tempdb, so restarting removed both the
table and the red icon.
Apparently sp_MSload_replication_status may clear this
error as well.
HTH,
Paul Ibison
(The ONLY sql server 2000 replication book:
http://www.nwsu.com/0974973602p.html)
removedbreplication didn't work. It appears the "new" "Database A" has no
knowledge of the replications. I'm not sure where replication monitor is
getting it's information from, but that is what needs clearing out.
sp_MSload_replication_status also didn't seem to help.
I can get the database rebooted over the weekend, but is there anything else
I can try or any reading I can do to help investigate.
Thanks
Derek
"Paul Ibison" wrote:

> Derek,
> can you run sp_removedbreplication in the previously
> published databases.
> If this doesn't remove the rogue red x's in replication
> monitor, try restarting the sql server service - when I
> have investigated this before, there is a reference to a
> temp table in tempdb, so restarting removed both the
> table and the red icon.
> Apparently sp_MSload_replication_status may clear this
> error as well.
> HTH,
> Paul Ibison
> (The ONLY sql server 2000 replication book:
> http://www.nwsu.com/0974973602p.html)
>
>

Invisible controls durig runtime

Hi,
Do you know why when I run my ssis packages in the dev machine, the diagrams are not visible during run time.
I can design the package but not sure why when I start the package, the diagrams in the control flow can not be viewed.
Please note that if I do this on the server, I can see the diagrams during run time.

Thanks

The controls or the diagram indicating the control/data flows? You change nouns between the subject and the body of this post. ("controls" versus "diagrams")

If the latter, are you sure you don't just need to scroll to the left, up, down, or to the right to see them?|||

Hi,

I mean the controls such as flat file source, ...

Thanks

invisible components

I am not sure why when the packages are run, the components dissapear. The only thing I see is the result in the output.

So there is no visual on the tabs.

Thanks

Could you provide more information on this. How do they disappear? Are you sure they are not just scrolled away due to your window layout in the debug mode?

Thanks,

Bob

|||

Simply, the components (flat file source, ole db source, etc...) disaapear as the package is run. I can only see what is happening in the output window.

Thanks

|||

arkiboys wrote:

Simply, the components (flat file source, ole db source, etc...) disaapear as the package is run. I can only see what is happening in the output window.

Thanks

Are you sure they just aren't to the side and that you need to scroll to see them? Look at the scroll bars in the design window and see if they are way off to the side.|||

Yes, I am sure.
There are no scroll bars during the run time.

Thanks

|||

arkiboys wrote:

Yes, I am sure.
There are no scroll bars during the run time.

Thanks

Any way you can capture a screen shot and send it to me via my e-mail listed in my profile?|||

Just sent email,

Thanks

|||

The email address phil_dot_brammer@.gmail.com bounced back.

Are you sure it works please?

|||You'll have to remove "_dot_" and replace it with "."|||That looks like the debug "Call Stack" window... Heck, I guess it even says so in the window title.

What happens when you go to "View -> Designer"?|||

You are right.
I did not notice the call stack window title.

Many thanks

Wednesday, March 28, 2012

Invalid Token

A client's SQL 7.0 installation seems to be
deteriorating. We have several stored procs that run on
as job scheduled. It started with one stored proc that
has been running for months with no problems all of the
sudden occasionally "sticking". By sticking I mean the
stored proc never completes. The stored proc is question
run another stored proc as part of the process. It
appears to be sticking on the call of the embedded stored
proc. If I run the embedded stored proc seperately, it
never sticks. If I run the entire process manually, it
will stick "some" of the time. If I cancel the stored
proc when it does stick I get a "Invalid Token" error
from SQL.
I have made several changes to the way the procs are
called and have included jobs to back up the DB and run
maintenance before the calls - and that has "helped" but
not solved the problem.
Now there are other jobs that are "sticking". One is an
import routine that has not been changed in 5 years nor
has it ever stuck before this week.
I think these are all symptoms of a bigger database
problem and not problems in the stored procs or jobs at
all.
Any ideas?What does DBCC CheckDB tell you?
--
Geoff N. Hiten
Microsoft SQL Server MVP
Senior Database Administrator
Careerbuilder.com
"Patrick" <anonymous@.discussions.microsoft.com> wrote in message
news:32e201c3b041$c3151f10$a601280a@.phx.gbl...
> A client's SQL 7.0 installation seems to be
> deteriorating. We have several stored procs that run on
> as job scheduled. It started with one stored proc that
> has been running for months with no problems all of the
> sudden occasionally "sticking". By sticking I mean the
> stored proc never completes. The stored proc is question
> run another stored proc as part of the process. It
> appears to be sticking on the call of the embedded stored
> proc. If I run the embedded stored proc seperately, it
> never sticks. If I run the entire process manually, it
> will stick "some" of the time. If I cancel the stored
> proc when it does stick I get a "Invalid Token" error
> from SQL.
> I have made several changes to the way the procs are
> called and have included jobs to back up the DB and run
> maintenance before the calls - and that has "helped" but
> not solved the problem.
> Now there are other jobs that are "sticking". One is an
> import routine that has not been changed in 5 years nor
> has it ever stuck before this week.
> I think these are all symptoms of a bigger database
> problem and not problems in the stored procs or jobs at
> all.
> Any ideas?
>|||CHECKDB found 0 allocation errors and 0 consistency errors
in database
>--Original Message--
>What does DBCC CheckDB tell you?
>--
>Geoff N. Hiten
>Microsoft SQL Server MVP
>Senior Database Administrator
>Careerbuilder.com|||Good, then there is nothing structurally wrong with your databases. The
'Invalid Token' message is likely a side effect of killing the process.
It may be that growth has changed the data so that SQL is generating
different query plans and they are now encountering locking and blocking
issues. I would check each query in the procedures and see what SQL thinks
the query plan is. You may find that modifying the index structure will
improve performance and decrease locking. There are also instances
(semi-rare) where the WITH RECOMPILE option may help. These almost always
involving a LIKE comparison that returns significantly different
percentages of the total rows in the table on subsequent calls to the proc.
--
Geoff N. Hiten
Microsoft SQL Server MVP
Senior Database Administrator
Careerbuilder.com
"Patrick" <anonymous@.discussions.microsoft.com> wrote in message
news:01c501c3b04d$17c6f0f0$a101280a@.phx.gbl...
> CHECKDB found 0 allocation errors and 0 consistency errors
> in database
> >--Original Message--
> >What does DBCC CheckDB tell you?
> >
> >--
> >Geoff N. Hiten
> >Microsoft SQL Server MVP
> >Senior Database Administrator
> >Careerbuilder.com
>|||Thanks for your help - but I am still stuck.
Here is what I have now - I am tracing the SP - my trace
is set to trace Locks and SP starts and completions.
I run a SP that hangs sometimes (an End of Day routine
that is VERY long of course) and I am having trouble
getting it to fail on my test DB. If I cannot get it to
fail, I move some statements around in the SP a bit and
recreate the proc, and then it might hang. I finally was
able to get a good trace on the SP when it had hung (this
SP normally takes less than 10 secs to complete).
The trace confused me because it shows that all the
statements started and completed, including the last
statement call (the main SP call). However, in query
analyser, the query is still running.
The trace also shows no locks.
These are the last two statements in the trace -
sys_sp_eod is the stored proc that I am executing in QA
that is not ever completing. Any more ideas on how to
trace this down?
+SP:StmtCompleted MS SQL Query Analyzer
WMS_ADMIN 0 10 0 0
2276 15 12:52:52.253
+SP:Completed sys_sp_EOD MS SQL Query Analyzer
WMS_ADMIN 0
2276 15 12:52:52.253|||Does your procedure mail out results using SQL Mail or SQL Agent Mail? If
so, it is probably stuck on a hung MAPI interface call.
--
Geoff N. Hiten
Microsoft SQL Server MVP
Senior Database Administrator
Careerbuilder.com
"Patrick" <anonymous@.discussions.microsoft.com> wrote in message
news:35dd01c3b05a$487e7c60$a601280a@.phx.gbl...
> Thanks for your help - but I am still stuck.
> Here is what I have now - I am tracing the SP - my trace
> is set to trace Locks and SP starts and completions.
> I run a SP that hangs sometimes (an End of Day routine
> that is VERY long of course) and I am having trouble
> getting it to fail on my test DB. If I cannot get it to
> fail, I move some statements around in the SP a bit and
> recreate the proc, and then it might hang. I finally was
> able to get a good trace on the SP when it had hung (this
> SP normally takes less than 10 secs to complete).
> The trace confused me because it shows that all the
> statements started and completed, including the last
> statement call (the main SP call). However, in query
> analyser, the query is still running.
> The trace also shows no locks.
>
> These are the last two statements in the trace -
> sys_sp_eod is the stored proc that I am executing in QA
> that is not ever completing. Any more ideas on how to
> trace this down?
> +SP:StmtCompleted MS SQL Query Analyzer
> WMS_ADMIN 0 10 0 0
> 2276 15 12:52:52.253
> +SP:Completed sys_sp_EOD MS SQL Query Analyzer
> WMS_ADMIN 0
> 2276 15 12:52:52.253
>|||No but maybe this is a clue? I have always suspected
something was amiss in our Receiving tables (this is a WMS
system) because of the SP is seems to get hung in and the
fact that the import SP is the new call that has been
hanging since yesterday - and it uses the receiving
tables. Here is something I found in the trace:
Event Class Text Application Name NT User
Name SQL User Name CPU Reads Writes Duration
Connection ID SPID Start Time
+Missing Column Statistics NO STATS:([Rcv_Doc].
[ORDER_DATE]) MS SQL Query Analyzer WMS_ADMIN
0 2276 15
13:49:59.770
+Missing Column Statistics NO STATS:([Rcv_Doc].
[ORDER_DATE]) MS SQL Query Analyzer WMS_ADMIN
0 2276 15
13:49:59.770
+Missing Column Statistics NO STATS:([RCV_DOC_DETAIL].
[LINE_NO]) MS SQL Query Analyzer WMS_ADMIN
0 2276 15
13:50:00.037
One of the first things I tried last week was running a
backup, statistics and the DB optimizations on the DB
before running EOD - and that seemed to help.
Are those warning above something that may be causing this?
>--Original Message--
>Does your procedure mail out results using SQL Mail or
SQL Agent Mail? If
>so, it is probably stuck on a hung MAPI interface call.
>|||Oh and Order_date is not part of any index..?
I ran DBCC Checktable and reindex - no help.
I read somewhere when doing a google seach that someone
fixed a similar problem by exporting the data, recreating
the tables, and reimporting. I hate to do that because
even if it solves the problem, in my mind it is not
fixed. Do you think that would help?
>+Missing Column Statistics NO STATS:([Rcv_Doc].
>[ORDER_DATE]) MS SQL Query Analyzer WMS_ADMIN
> 0 2276 15
> 13:49:59.770|||Well recreating those table did not help.
I also added an index on order_date just for kicks and it
made the error go away - but same ultimate result - the SP
hanging. I removed the index and the warning came back.
Interestingly enough, the other warning on Line_no for the
other table has not been warning since the tables were
recreated. There IS an index on that col as it is part of
the PK.|||Maybe it is fixed' I went back and did add the WITH
RECOMPILE option and it has now run about 20 times
straight. That is not 100% guranteed indicator which is
what is making this SO frustrating - it has worked after
other changes for a little while.
But I am hoping that fixes it. Have you seen it cause
exactly what I describe if you do not have that option
set? The queries do not use the LIKE clause and this
basic EOD routine has been in production for years..|||There are other issues with SP plan reuse, especially with SQL 7.0. Most of
the time reuse is a good thing. Sometimes it is not, especially with result
sets that vary widely in size. If the WITH RECOMPILE works and solves this
problem, then move on to the next one.
--
Geoff N. Hiten
Microsoft SQL Server MVP
Senior Database Administrator
Careerbuilder.com
"Patrick" <anonymous@.discussions.microsoft.com> wrote in message
news:094001c3b070$97f61b20$a001280a@.phx.gbl...
> Maybe it is fixed' I went back and did add the WITH
> RECOMPILE option and it has now run about 20 times
> straight. That is not 100% guranteed indicator which is
> what is making this SO frustrating - it has worked after
> other changes for a little while.
> But I am hoping that fixes it. Have you seen it cause
> exactly what I describe if you do not have that option
> set? The queries do not use the LIKE clause and this
> basic EOD routine has been in production for years..
>sql

Monday, March 26, 2012

Invalid Report Source

I developed a project with a form one main report and three subreports.

I was able to run this report well in this project.

But if i include it in my main project it throws an error "Invalid Report Source" and my viewer is blank but the "Main Report" tab is there present.

I use dataset as the datasource for my crystal report.
If i use the dataset to fill my datagrid it is giving the value.

So with the situation i understand that the dataset is getting filled and the report is also geting the data. The error comes in the line

RptViewer.ReportSource = Rpt_Doc. '(Report Document Object)

One main thing is i have not used any error handler but the code still continue to work properly without being crashed.

If i give 'Try catch' error handler also i the same error is only prompted.

The main project was first developed in vs.net 2000 and the project was upgraded to 2003.

Will this be the reason for the report being giving the errorI got the solution through one of my friend.

she got it from another friend.

So that was a long chani to get the solution

the solution is

The error message appears because the incorrect versions of the Crystal DLL files are referenced.

To correct this behavior reference the correct version of Crystal DLL files.

Adding the Correct References
----------

1. Open the VS .NET project.

2. In the 'Solution Explorer' window, right-click the 'References' folder and choose the 'Add Reference' command. The 'Add Reference' window appears.

3. Verify the References for all Crystal DLLs are version 9.1.5000. If they are not version 9.1.5000, select the 9.1.5000 version DLLs and click the 'Select' button.

4. Click the 'OK' button.

5. Save and run your application.

If running the application you find the DLLs revert to the version observed prior to your updates, complete the following steps:

Reverting DLLs Back to Version 9.1.5000
------------

1. Right-click the project name in the solution explorer and select the 'Properties' command. The 'Properties' window appears.

2. Under the 'Common Properties' folder, select 'References Path'. The 'Reference Path' window appears.

3. Delete all entries in this window and click 'OK'.

4. Repeat steps 2 through 4 of the 'Steps to Add the Correct References Section'.

Upon completing the listed steps, the application runs and reflects the correct References.

she send me this thru my mail i have copied and pasted it here

so it may be helpful to other who visit this forum

Thanks a lot for all those who tried to solve this problem.

dont forget to rate my post

Invalid OS SP when installing sql beta 2005 IA64

When I run setup I get an error stating the OS is not at the required Servic
e
Pack. I looked over the requirements and Data Center with a build over 1138
was suffecient. I am running Data Center IA64, and I am trying to install
2005 beta dev IA64.Can you please post to the SQL Server 2005 newsgroups?
http://www.aspfaq.com/sql2005/show.asp?id=1
http://www.aspfaq.com/
(Reverse address to reply.)
"cw" <cw@.discussions.microsoft.com> wrote in message
news:980CBE28-C7A1-4499-BE40-209D849C49EB@.microsoft.com...
> When I run setup I get an error stating the OS is not at the required
Service
> Pack. I looked over the requirements and Data Center with a build over
1138
> was suffecient. I am running Data Center IA64, and I am trying to install
> 2005 beta dev IA64.

Invalid OS SP when installing sql beta 2005 IA64

When I run setup I get an error stating the OS is not at the required Service
Pack. I looked over the requirements and Data Center with a build over 1138
was suffecient. I am running Data Center IA64, and I am trying to install
2005 beta dev IA64.Can you please post to the SQL Server 2005 newsgroups?
http://www.aspfaq.com/sql2005/show.asp?id=1
--
http://www.aspfaq.com/
(Reverse address to reply.)
"cw" <cw@.discussions.microsoft.com> wrote in message
news:980CBE28-C7A1-4499-BE40-209D849C49EB@.microsoft.com...
> When I run setup I get an error stating the OS is not at the required
Service
> Pack. I looked over the requirements and Data Center with a build over
1138
> was suffecient. I am running Data Center IA64, and I am trying to install
> 2005 beta dev IA64.

Invalid OS SP when installing sql beta 2005 IA64

When I run setup I get an error stating the OS is not at the required Service
Pack. I looked over the requirements and Data Center with a build over 1138
was suffecient. I am running Data Center IA64, and I am trying to install
2005 beta dev IA64.
Can you please post to the SQL Server 2005 newsgroups?
http://www.aspfaq.com/sql2005/show.asp?id=1
http://www.aspfaq.com/
(Reverse address to reply.)
"cw" <cw@.discussions.microsoft.com> wrote in message
news:980CBE28-C7A1-4499-BE40-209D849C49EB@.microsoft.com...
> When I run setup I get an error stating the OS is not at the required
Service
> Pack. I looked over the requirements and Data Center with a build over
1138
> was suffecient. I am running Data Center IA64, and I am trying to install
> 2005 beta dev IA64.

Invalid operator for data type.

Kudos to y'all experts out there. I kinda needed your help. I'm trying to run a query...

SELECT a.AUF_POS AS Pos, c.ZL_STR AS Panel, a.POS_TEXT AS Description, a.BREITE AS W1, a.HOEHE

AS H1, a.BREITE2 AS W2, a.HOEHE2 AS H2, SUM(b.ANZ) AS Qty, SUM(b.LIEFER_ANZ) AS Dlvd,

SUM(b.RG_ANZ) AS Inv, (a.BREITE*a.HOEHE/CAST(1000000 AS NUMERIC)) AS UnitSQM,

(a.BREITE*a.HOEHE*SUM(b.ANZ)/CAST(1000000 AS NUMERIC)) as TotPosSQM

FROM liorder..LIORDER.AUF_POS a INNER JOIN liorder..LIORDER.AUF_STAT b ON a.AUF_NR = b.AUF_NR

AND a.AUF_POS = b.AUF_POS INNER JOIN liorder..LIORDER.AUF_TEXT c ON a.AUF_NR = c.AUF_NR AND

b.AUF_POS = c.AUF_POS

WHERE (c.ZL_MOD = 0) AND (b.AUF_NR = '86260')

GROUP BY a.AUF_POS, a.POS_TEXT, a.BREITE, a.BREITE2, a.HOEHE, a.HOEHE2, a.SFORM_NR, c.ZL_STR

...and I keep getting this error: Invalid operator for data type. Operator equals multiply, type equals nvarchar. I've tried every possible CAST and CONVERT but I just can't make it work. I'm pretty sure that the data types for the columns I mentioned on the mathematical equation are all numeric. Please help...Its going to be difficult for us to help without the DDL. Your query does alot of aggregrations (i.e. sum/avg/etc), thus you'd want to ensure that the column datatype is numeric.

Friday, March 23, 2012

Invalid object name 'ReportServerTempDB.dbo.PersistedStream'

Hi,
I've restored my report server 2005 from serverA to serverB and
Reporting Services will run and I can access the reports, but the
above error will pop whenever I try to run a report. I followed the
steps outlined below - where did I go wrong?
1) backed up the encryption key on serverA
2) backed up the report server databases on both servers
3) shut down RS on serverB
4) detached the reportserver database on serverB
5) renamed reportserver.mdf and ldf to reportserver.mdf_old and
reportserver.ldf_old
6) restored reportserver.mdf and ldf from serverA onto serverB
7) started reporting services on serverB - failed to initialize
8) restored encryption key and then deleted the row from
REPORTSERVER.DBO.KEYS where machinename = 'serverB'
9) restarted reporting services and the pages displayed
10) accessed the report that I wanted to view and the error above
popped
11) tried deleting and re-creating reportserverTempDB by dropping and
recreating from the CatalogTemp.sql file from the install - made sure
that the collations matched
Here is the error text:
ReportingServicesService!runningjobs!4!4/3/2007-09:17:42:: e ERROR:
Error in timer Database Cleanup (NT Service) :
System.Data.SqlClient.SqlException: Invalid object name
'ReportServerTempDB.dbo.PersistedStream'.
at System.Data.SqlClient.SqlConnection.OnError(SqlException
exception, Boolean breakConnection)
at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException
exception, Boolean breakConnection)
at
System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject
stateObj)
at System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior,
SqlCommand cmdHandler, SqlDataReader dataStream,
BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject
stateObj)
at
System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds,
RunBehavior runBehavior, String resetOptionsString)
at
System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior
cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean
async)
at
System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior
cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String
method, DbAsyncResult result)
at
System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(DbAsyncResult
result, String methodName, Boolean sendToPipe)
at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
at
Microsoft.ReportingServices.Library.InstrumentedSqlCommand.ExecuteNonQuery()
at
Microsoft.ReportingServices.Library.DatabaseCleanupTimer.CleanBatch()
at
Microsoft.ReportingServices.Library.DatabaseCleanupTimer.DoTimerAction()
at
Microsoft.ReportingServices.Diagnostics.TimerActionBase.TimerAction(Object
unused)On Apr 3, 10:41 am, "Tim" <timgoldenst...@.msn.com> wrote:
> Hi,
> I've restored my report server 2005 from serverA to serverB and
> Reporting Services will run and I can access the reports, but the
> above error will pop whenever I try to run a report. I followed the
> steps outlined below - where did I go wrong?
> 1) backed up the encryption key on serverA
> 2) backed up the report server databases on both servers
> 3) shut down RS on serverB
> 4) detached the reportserver database on serverB
> 5) renamed reportserver.mdf and ldf to reportserver.mdf_old and
> reportserver.ldf_old
> 6) restored reportserver.mdf and ldf from serverA onto serverB
> 7) started reporting services on serverB - failed to initialize
> 8) restored encryption key and then deleted the row from
> REPORTSERVER.DBO.KEYS where machinename => 'serverB'
> 9) restarted reporting services and the pages displayed
> 10) accessed the report that I wanted to view and the error above
> popped
> 11) tried deleting and re-creating reportserverTempDB by dropping and
> recreating from the CatalogTemp.sql file from the install - made sure
> that the collations matched
> Here is the error text:
> ReportingServicesService!runningjobs!4!4/3/2007-09:17:42:: e ERROR:
> Error in timer Database Cleanup (NT Service) :
> System.Data.SqlClient.SqlException: Invalid object name
> 'ReportServerTempDB.dbo.PersistedStream'.
> at System.Data.SqlClient.SqlConnection.OnError(SqlException
> exception, Boolean breakConnection)
> at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException
> exception, Boolean breakConnection)
> at
> System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject
> stateObj)
> at System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior,
> SqlCommand cmdHandler, SqlDataReader dataStream,
> BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject
> stateObj)
> at
> System.Data.SqlClient.SqlCommand.FinishExecuteReader(SqlDataReader ds,
> RunBehavior runBehavior, String resetOptionsString)
> at
> System.Data.SqlClient.SqlCommand.RunExecuteReaderTds(CommandBehavior
> cmdBehavior, RunBehavior runBehavior, Boolean returnStream, Boolean
> async)
> at
> System.Data.SqlClient.SqlCommand.RunExecuteReader(CommandBehavior
> cmdBehavior, RunBehavior runBehavior, Boolean returnStream, String
> method, DbAsyncResult result)
> at
> System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(DbAsyncResult
> result, String methodName, Boolean sendToPipe)
> at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
> at
> Microsoft.ReportingServices.Library.InstrumentedSqlCommand.ExecuteNonQuery()
> at
> Microsoft.ReportingServices.Library.DatabaseCleanupTimer.CleanBatch()
> at
> Microsoft.ReportingServices.Library.DatabaseCleanupTimer.DoTimerAction()
> at
> Microsoft.ReportingServices.Diagnostics.TimerActionBase.TimerAction(Object
> unused)
This MS article might be of assistance.
http://msdn2.microsoft.com/en-us/library/ms159093.aspx
Regards,
Enrique Martinez
Sr. Software Consultant|||Thanks Enrique - it turned out to be a permissions issue on the
ReportServerTempDB in that RSExecRole role

Invalid object name 'Product'.

HI I'M NEWBIES in visual Basic with Sql Server
i try to make a database with stored procedure and whan i run the program the give an error

"Invalid object name 'Product'."

i dont know how to fix it here is my code
Dim sqlcon As New SqlClient.SqlConnection
sqlcon.ConnectionString = "Data Source=WISEMAN\SQLEXPRESS;Initial Catalog=Product;Integrated Security=True;Pooling=False;uid=uid;pwd=pwd "
Dim cmd As New SqlClient.SqlCommand
cmd.Connection = sqlcon
cmd.CommandType = CommandType.StoredProcedure
cmd.CommandText = "insertcustomer"
cmd.Parameters.AddWithValue("@.Productid", TextBox1.Text)
cmd.Parameters.AddWithValue("@.detail", TextBox2.Text)
sqlcon.Open()
cmd.ExecuteScalar()
cmd.ExecuteNonQuery()
sqlcon.Close()

the error at line is cmd.executescalar()
My database name is product
my name for my storedprocedure is insertcustomer
Code for insertcustomer
ALTER PROCEDURE dbo.InsertCustomer
(

@.ProductID int output,
@.detail varchar(50)
)

AS
SET NOCOUNT ON

INSERT INTO Productdetail
(detail)
VALUES
(@.detail);

IF @.@.ROWCOUNT>0 AND @.@.ERROR>0

SELECT @.Detail = detail

From Productdetail
Where (ProductID =SCOPE_IDENTITY())

if u have any idee please tell meHi shadwise,

Welcome to thescripts. I'm sure you will find a wealth of information ion the various forums here. I am moving this thread to the SQL server forum. You will still be able to access this particular thread through the introductions page, but future questions should be directed to the appropriate forum (which you will find by selecting "forums" on the blue bar near the top of your screen.

I hope the experts in the SQL server forum can help with your query!!|||

Quote:

Originally Posted by shadwise

...i dont know how to fix it here is my code...
if u have any idee please tell me


Does your server or database have case-sensitive collation? Please copy/paste complete error description.
I'm not sure about "Invalid object name 'Product'" problem, but there are several other problem worth mentioning:Wrap SqlConnection and SqlCommand scope with using (C# keyword, don't know correct VB syntax)

Invalid object name 'information_schema.constraint_table_usage'

I created a new database on a SQL 2005 server, which also contains other
databases. I just tried to run "select * from
information_schema.constraint_table_usage" and got an error Msg 208, Level
16, State 1, Line 1
Invalid object name 'information_schema.constraint_table_usage'.
However I can run the select statement on the other databases and get the
information back.
Anyone have any idea why it wouldn't work on one database but does on other's.
Thanks in advance.
Possibly a permissions issue?
"scuba79" <scuba79@.discussions.microsoft.com> wrote in message
news:4835E0D8-D980-4C60-A2D2-A6BDFAD2D91D@.microsoft.com...
>I created a new database on a SQL 2005 server, which also contains other
> databases. I just tried to run "select * from
> information_schema.constraint_table_usage" and got an error Msg 208, Level
> 16, State 1, Line 1
> Invalid object name 'information_schema.constraint_table_usage'.
> However I can run the select statement on the other databases and get the
> information back.
> Anyone have any idea why it wouldn't work on one database but does on
> other's.
> Thanks in advance.
|||> My guess is that the database is case-sensitive. The info schema view
> names are all upper-case.
Of course, duh. I was going to suggest compatibility level next. :-)
|||That was the issue, thought I created it case-insensitive...
"Tibor Karaszi" wrote:

> My guess is that the database is case-sensitive. The info schema view names are all upper-case.
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://sqlblog.com/blogs/tibor_karaszi
>
> "scuba79" <scuba79@.discussions.microsoft.com> wrote in message
> news:4835E0D8-D980-4C60-A2D2-A6BDFAD2D91D@.microsoft.com...
>
>

Invalid object name 'information_schema.constraint_table_usage'

I created a new database on a SQL 2005 server, which also contains other
databases. I just tried to run "select * from
information_schema.constraint_table_usage" and got an error Msg 208, Level
16, State 1, Line 1
Invalid object name 'information_schema.constraint_table_usage'.
However I can run the select statement on the other databases and get the
information back.
Anyone have any idea why it wouldn't work on one database but does on other's.
Thanks in advance.Possibly a permissions issue?
"scuba79" <scuba79@.discussions.microsoft.com> wrote in message
news:4835E0D8-D980-4C60-A2D2-A6BDFAD2D91D@.microsoft.com...
>I created a new database on a SQL 2005 server, which also contains other
> databases. I just tried to run "select * from
> information_schema.constraint_table_usage" and got an error Msg 208, Level
> 16, State 1, Line 1
> Invalid object name 'information_schema.constraint_table_usage'.
> However I can run the select statement on the other databases and get the
> information back.
> Anyone have any idea why it wouldn't work on one database but does on
> other's.
> Thanks in advance.|||My guess is that the database is case-sensitive. The info schema view names are all upper-case.
--
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://sqlblog.com/blogs/tibor_karaszi
"scuba79" <scuba79@.discussions.microsoft.com> wrote in message
news:4835E0D8-D980-4C60-A2D2-A6BDFAD2D91D@.microsoft.com...
>I created a new database on a SQL 2005 server, which also contains other
> databases. I just tried to run "select * from
> information_schema.constraint_table_usage" and got an error Msg 208, Level
> 16, State 1, Line 1
> Invalid object name 'information_schema.constraint_table_usage'.
> However I can run the select statement on the other databases and get the
> information back.
> Anyone have any idea why it wouldn't work on one database but does on other's.
> Thanks in advance.|||> My guess is that the database is case-sensitive. The info schema view
> names are all upper-case.
Of course, duh. I was going to suggest compatibility level next. :-)|||That was the issue, thought I created it case-insensitive...
"Tibor Karaszi" wrote:
> My guess is that the database is case-sensitive. The info schema view names are all upper-case.
> --
> Tibor Karaszi, SQL Server MVP
> http://www.karaszi.com/sqlserver/default.asp
> http://sqlblog.com/blogs/tibor_karaszi
>
> "scuba79" <scuba79@.discussions.microsoft.com> wrote in message
> news:4835E0D8-D980-4C60-A2D2-A6BDFAD2D91D@.microsoft.com...
> >I created a new database on a SQL 2005 server, which also contains other
> > databases. I just tried to run "select * from
> > information_schema.constraint_table_usage" and got an error Msg 208, Level
> > 16, State 1, Line 1
> > Invalid object name 'information_schema.constraint_table_usage'.
> >
> > However I can run the select statement on the other databases and get the
> > information back.
> >
> > Anyone have any idea why it wouldn't work on one database but does on other's.
> >
> > Thanks in advance.
>
>sql

Invalid object name 'information_schema.constraint_table_usage'

I created a new database on a SQL 2005 server, which also contains other
databases. I just tried to run "select * from
information_schema.constraint_table_usage" and got an error Msg 208, Level
16, State 1, Line 1
Invalid object name 'information_schema.constraint_table_usage'.
However I can run the select statement on the other databases and get the
information back.
Anyone have any idea why it wouldn't work on one database but does on other'
s.
Thanks in advance.Possibly a permissions issue?
"scuba79" <scuba79@.discussions.microsoft.com> wrote in message
news:4835E0D8-D980-4C60-A2D2-A6BDFAD2D91D@.microsoft.com...
>I created a new database on a SQL 2005 server, which also contains other
> databases. I just tried to run "select * from
> information_schema.constraint_table_usage" and got an error Msg 208, Level
> 16, State 1, Line 1
> Invalid object name 'information_schema.constraint_table_usage'.
> However I can run the select statement on the other databases and get the
> information back.
> Anyone have any idea why it wouldn't work on one database but does on
> other's.
> Thanks in advance.|||My guess is that the database is case-sensitive. The info schema view names
are all upper-case.
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://sqlblog.com/blogs/tibor_karaszi
"scuba79" <scuba79@.discussions.microsoft.com> wrote in message
news:4835E0D8-D980-4C60-A2D2-A6BDFAD2D91D@.microsoft.com...
>I created a new database on a SQL 2005 server, which also contains other
> databases. I just tried to run "select * from
> information_schema.constraint_table_usage" and got an error Msg 208, Level
> 16, State 1, Line 1
> Invalid object name 'information_schema.constraint_table_usage'.
> However I can run the select statement on the other databases and get the
> information back.
> Anyone have any idea why it wouldn't work on one database but does on othe
r's.
> Thanks in advance.|||> My guess is that the database is case-sensitive. The info schema view
> names are all upper-case.
Of course, duh. I was going to suggest compatibility level next. :-)

Invalid object name in stored procedure

-- In SQL Server 2000
--When run from Query Analyzer I correctly get identification of line
numbers having duplicate values of SKU_NameUsedBySCS:
-- LineNumber1 LineNumber2
-- 2 5
-- but when I try to create a stored procedure having this same code I get:
-- Invalid object name '#x'.
IF not EXISTS (SELECT name FROM sysobjects WHERE name = 'PermTable' )
begin
create table PermTable (scs_id int, sku_nameusedbyscs nvarchar(40))
insert into PermTable VALUES (11, 'name23')
insert into PermTable VALUES (11, 'name81')
insert into PermTable VALUES (11, 'name27')
insert into PermTable VALUES (11, 'name88')
insert into PermTable VALUES (11, 'name81')
end
declare @.SCS_ID int
set @.SCS_ID =11
set nocount on
select identity(int,1,1) as Sequence, scs_id,sku_nameusedbyscs into #x from
PermTable WHERE SCS_ID =@.SCS_ID
go
select top 40 min(Sequence) as LineNumber1, max(Sequence) as LineNumber2
from #x GROUP BY SKU_NameUsedBySCS having count(*) > 1
drop table #x
gohello steve, did you check previous error messages? is you database Case
Sensitive? If it is, then the select into statement must have the names of
your fields in lower case.
hope this helps.
"SteveInSC" wrote:

> -- In SQL Server 2000
> --When run from Query Analyzer I correctly get identification of line
> numbers having duplicate values of SKU_NameUsedBySCS:
> -- LineNumber1 LineNumber2
> -- 2 5
> -- but when I try to create a stored procedure having this same code I get
:
> -- Invalid object name '#x'.
>
> IF not EXISTS (SELECT name FROM sysobjects WHERE name = 'PermTable' )
> begin
> create table PermTable (scs_id int, sku_nameusedbyscs nvarchar(40))
> insert into PermTable VALUES (11, 'name23')
> insert into PermTable VALUES (11, 'name81')
> insert into PermTable VALUES (11, 'name27')
> insert into PermTable VALUES (11, 'name88')
> insert into PermTable VALUES (11, 'name81')
> end
> declare @.SCS_ID int
> set @.SCS_ID =11
> set nocount on
> select identity(int,1,1) as Sequence, scs_id,sku_nameusedbyscs into #x fro
m
> PermTable WHERE SCS_ID =@.SCS_ID
> go
> select top 40 min(Sequence) as LineNumber1, max(Sequence) as LineNumber2
> from #x GROUP BY SKU_NameUsedBySCS having count(*) > 1
> drop table #x
> go
>
>|||Hi
And where do you create the temporary table #x?
John
"SteveInSC" wrote:

> -- In SQL Server 2000
> --When run from Query Analyzer I correctly get identification of line
> numbers having duplicate values of SKU_NameUsedBySCS:
> -- LineNumber1 LineNumber2
> -- 2 5
> -- but when I try to create a stored procedure having this same code I get
:
> -- Invalid object name '#x'.
>
> IF not EXISTS (SELECT name FROM sysobjects WHERE name = 'PermTable' )
> begin
> create table PermTable (scs_id int, sku_nameusedbyscs nvarchar(40))
> insert into PermTable VALUES (11, 'name23')
> insert into PermTable VALUES (11, 'name81')
> insert into PermTable VALUES (11, 'name27')
> insert into PermTable VALUES (11, 'name88')
> insert into PermTable VALUES (11, 'name81')
> end
> declare @.SCS_ID int
> set @.SCS_ID =11
> set nocount on
> select identity(int,1,1) as Sequence, scs_id,sku_nameusedbyscs into #x fro
m
> PermTable WHERE SCS_ID =@.SCS_ID
> go
> select top 40 min(Sequence) as LineNumber1, max(Sequence) as LineNumber2
> from #x GROUP BY SKU_NameUsedBySCS having count(*) > 1
> drop table #x
> go
>
>|||At the time the proc is compiled the #x table does not exist as it's
created at runtime. So when you try to compile the code to get an
execution plan the query optimiser cannot create a plan involving #x
because it doesn't yet exist.
Try creating the temp table explicitly in the proc and then inserting
into it with a normal INSERT statement (rather than SELECT ... INTO).
*mike hodgson* |/ database administrator/ | mallesons stephen jaques
*T* +61 (2) 9296 3668 |* F* +61 (2) 9296 3885 |* M* +61 (408) 675 907
*E* mailto:mike.hodgson@.mallesons.nospam.com |* W* http://www.mallesons.com
SteveInSC wrote:

>-- In SQL Server 2000
>--When run from Query Analyzer I correctly get identification of line
>numbers having duplicate values of SKU_NameUsedBySCS:
>-- LineNumber1 LineNumber2
>-- 2 5
>-- but when I try to create a stored procedure having this same code I get:
>-- Invalid object name '#x'.
>
>IF not EXISTS (SELECT name FROM sysobjects WHERE name = 'PermTable' )
> begin
> create table PermTable (scs_id int, sku_nameusedbyscs nvarchar(40))
> insert into PermTable VALUES (11, 'name23')
> insert into PermTable VALUES (11, 'name81')
> insert into PermTable VALUES (11, 'name27')
> insert into PermTable VALUES (11, 'name88')
> insert into PermTable VALUES (11, 'name81')
> end
>declare @.SCS_ID int
>set @.SCS_ID =11
>set nocount on
>select identity(int,1,1) as Sequence, scs_id,sku_nameusedbyscs into #x from
>PermTable WHERE SCS_ID =@.SCS_ID
>go
>select top 40 min(Sequence) as LineNumber1, max(Sequence) as LineNumber2
>from #x GROUP BY SKU_NameUsedBySCS having count(*) > 1
>drop table #x
>go
>
>
>|||Hi Steve
If you have simply created the stored procedure by wrapping the SQL below in
a create procedure call then you have a GO in the middle of the declaration.
This will terminate the declaration.
Query Analyser will then try to run the later commands as immediate
commands. As the table is created by the SELECT ... INTO inside the
definition it will not find it for the later SELECT statement.
Try removing the GO statement in the middle of the declaration if there is
one.
As a separate point I would recommend using a Table variable (you know the
structure you want) as the scope is much better defined.
I hope this helps
Alasdair Russell
"SteveInSC" wrote:

> -- In SQL Server 2000
> --When run from Query Analyzer I correctly get identification of line
> numbers having duplicate values of SKU_NameUsedBySCS:
> -- LineNumber1 LineNumber2
> -- 2 5
> -- but when I try to create a stored procedure having this same code I get
:
> -- Invalid object name '#x'.
>
> IF not EXISTS (SELECT name FROM sysobjects WHERE name = 'PermTable' )
> begin
> create table PermTable (scs_id int, sku_nameusedbyscs nvarchar(40))
> insert into PermTable VALUES (11, 'name23')
> insert into PermTable VALUES (11, 'name81')
> insert into PermTable VALUES (11, 'name27')
> insert into PermTable VALUES (11, 'name88')
> insert into PermTable VALUES (11, 'name81')
> end
> declare @.SCS_ID int
> set @.SCS_ID =11
> set nocount on
> select identity(int,1,1) as Sequence, scs_id,sku_nameusedbyscs into #x fro
m
> PermTable WHERE SCS_ID =@.SCS_ID
> go
> select top 40 min(Sequence) as LineNumber1, max(Sequence) as LineNumber2
> from #x GROUP BY SKU_NameUsedBySCS having count(*) > 1
> drop table #x
> go
>
>|||Comment out the first "GO" and you will be all set.
Try this:
create procedure sp_abc as
IF not EXISTS (SELECT name FROM sysobjects WHERE name = 'PermTable' )
begin
create table PermTable (scs_id int, sku_nameusedbyscs nvarchar(40))
insert into PermTable VALUES (11, 'name23')
insert into PermTable VALUES (11, 'name81')
insert into PermTable VALUES (11, 'name27')
insert into PermTable VALUES (11, 'name88')
insert into PermTable VALUES (11, 'name81')
end
declare @.SCS_ID int
set @.SCS_ID =11
set nocount on
select identity(int,1,1) as Sequence, scs_id,sku_nameusedbyscs into #x
from
PermTable WHERE SCS_ID =@.SCS_ID
-- ############## MySQLServer ############ --go
select top 40 min(Sequence) as LineNumber1, max(Sequence) as
LineNumber2
from #x GROUP BY SKU_NameUsedBySCS having count(*) > 1
drop table #x
go
SteveInSC wrote:
> -- In SQL Server 2000
> --When run from Query Analyzer I correctly get identification of line
> numbers having duplicate values of SKU_NameUsedBySCS:
> -- LineNumber1 LineNumber2
> -- 2 5
> -- but when I try to create a stored procedure having this same code I get
:
> -- Invalid object name '#x'.
>
> IF not EXISTS (SELECT name FROM sysobjects WHERE name = 'PermTable' )
> begin
> create table PermTable (scs_id int, sku_nameusedbyscs nvarchar(40))
> insert into PermTable VALUES (11, 'name23')
> insert into PermTable VALUES (11, 'name81')
> insert into PermTable VALUES (11, 'name27')
> insert into PermTable VALUES (11, 'name88')
> insert into PermTable VALUES (11, 'name81')
> end
> declare @.SCS_ID int
> set @.SCS_ID =11
> set nocount on
> select identity(int,1,1) as Sequence, scs_id,sku_nameusedbyscs into #x fro
m
> PermTable WHERE SCS_ID =@.SCS_ID
> go
> select top 40 min(Sequence) as LineNumber1, max(Sequence) as LineNumber2
> from #x GROUP BY SKU_NameUsedBySCS having count(*) > 1
> drop table #x
> go|||You forgot to remove the "GO" before the "SELECT TOP 40".
Razvan

Invalid Object Name - Weird Error - Help!

You may want to run DBCC CHECKCATALOG to check the system
tables.
Mark Baekdal
www.dbghost.com - the only true Database Change Manager
for SQL Server.

>--Original Message--
>I have a really strange problem. It seems a table has
gone invisible. It's
>listed in SysObjects, but does not show up in the tables
list.
>When I execte "Select * From Object_Access_Levels", it
raises the error "Invalid
>Object Name".
>If I try to [Drop Table Object_Access_Levels], it
returns the error:
> "Cannot drop the table 'Object_Access_Levels' because
it does not exist in the
>system catalog."
>If I follow the ID for the table to Syscolumns and
SysIndexes, all the records
>are there.
>This is a complete show-stopper. I cannot continue
development until this table
>is restored.
>Here's a copy of the record from sysobjects:
> name,id,xtype,uid,info,status,base_schem
a_ver,replinfo,pa
rent_obj,crdate,ftcatid,
> schema_ver,stats_schema_ver,type,usersta
t,sysstat,indexde
l,refdate,version,deltri
> g,instrig,updtrig,seltrig,category,cache
>"Object_Access_Levels",1858821684,"U ",1,17,8451,272,0,0,
"07/12/2002
>02:09pm",0,272,0,"U ",1,115,0,"07/12/2002
02:09pm",0,,,,0,2560,0
>Does anyone have a clue how I can fix this problem?
>I am using SQL2K with SP3a.
>TIA,
>-Steve-
>
>.
>Hi Mark,
Running: DBCC CHECKCATALOG ('MedMas') WITH NO_INFOMSGS
Returns this error:
[Table Corrupt: Object ID 1840725610 (object '1840725610') does not matc
h between
'SYSCOLUMNS' and 'SYSOBJECTS']
Is this fixable without rebuilding the database?
Thanks,
-Steve-
"mark baekdal" <anonymous@.discussions.microsoft.com> wrote in message
news:26ebb01c46255$b2dbd4b0$a301280a@.phx
.gbl...
You may want to run DBCC CHECKCATALOG to check the system
tables.
Mark Baekdal
www.dbghost.com - the only true Database Change Manager
for SQL Server.|||BTW, I just checked the ID 1840725610, it doesn't belong the Object_Access_L
evels
table. It belongs to a couple of params. I think this DB is really hosed!
-Steve-
"Steve Zimmelman" <sk_z@.psi_med.com> wrote in message
news:%23JR2N$oYEHA.1764@.TK2MSFTNGP10.phx.gbl...
Hi Mark,
Running: DBCC CHECKCATALOG ('MedMas') WITH NO_INFOMSGS
Returns this error:
[Table Corrupt: Object ID 1840725610 (object '1840725610') does not matc
h between
'SYSCOLUMNS' and 'SYSOBJECTS']
Is this fixable without rebuilding the database?
Thanks,
-Steve-
"mark baekdal" <anonymous@.discussions.microsoft.com> wrote in message
news:26ebb01c46255$b2dbd4b0$a301280a@.phx
.gbl...
You may want to run DBCC CHECKCATALOG to check the system
tables.
Mark Baekdal
www.dbghost.com - the only true Database Change Manager
for SQL Server.|||Steve,
Any idea what error message(s) you were getting? If
error 2513, check SQL Books Online for steps to possibly
resolve the inconsistency. Please ensure you have a
backup or copy of the .mdf & .ldf before you do anything.
HTH
Darren Fuller

>--Original Message--
>Hi Mark,
>Running: DBCC CHECKCATALOG ('MedMas') WITH NO_INFOMSGS
>Returns this error:
>[Table Corrupt: Object ID 1840725610
(object '1840725610') does not match between
>'SYSCOLUMNS' and 'SYSOBJECTS']
>Is this fixable without rebuilding the database?
>Thanks,
>-Steve-
>"mark baekdal" <anonymous@.discussions.microsoft.com>
wrote in message
> news:26ebb01c46255$b2dbd4b0$a301280a@.phx
.gbl...
>You may want to run DBCC CHECKCATALOG to check the system
>tables.
>Mark Baekdal
>www.dbghost.com - the only true Database Change Manager
>for SQL Server.
>
>.
>|||After much wasted time, I restored an old copy of the db. I was under the
impression (apparently a false one) that SQL server didn't have these types
corruption problems.
Thanks everyone for your suggestions.
-Steve-|||Your impression is not false, we don't have these types of corruption
problems.
However, hardware can and does introduce all manner of corruptions that
manifest themselves in various ways. I would check your NT event logs and
SQL errorlog for IO susbsystem errors. Before restoring from your backup, I
would have recommended running DBCC CHECKDB to check for other corruptions.
In future, to avoid wasting time, you should call Product Support who will
be able to help you pinpoint the problem very quickly.
Regards.
Paul Randal
Dev Lead, Microsoft SQL Server Storage Engine
This posting is provided "AS IS" with no warranties, and confers no rights.
"Steve Zimmelman" <sk_z@.psi_med.com> wrote in message
news:ermVPB6YEHA.1048@.tk2msftngp13.phx.gbl...
> After much wasted time, I restored an old copy of the db. I was under the
> impression (apparently a false one) that SQL server didn't have these
types
> corruption problems.
> Thanks everyone for your suggestions.
> -Steve-
>

Invalid Object Name - Weird Error - Help!

You may want to run DBCC CHECKCATALOG to check the system
tables.
Mark Baekdal
www.dbghost.com - the only true Database Change Manager
for SQL Server.

>--Original Message--
>I have a really strange problem. It seems a table has
gone invisible. It's
>listed in SysObjects, but does not show up in the tables
list.
>When I execte "Select * From Object_Access_Levels", it
raises the error "Invalid
>Object Name".
>If I try to [Drop Table Object_Access_Levels], it
returns the error:
> "Cannot drop the table 'Object_Access_Levels' because
it does not exist in the
>system catalog."
>If I follow the ID for the table to Syscolumns and
SysIndexes, all the records
>are there.
>This is a complete show-stopper. I cannot continue
development until this table
>is restored.
>Here's a copy of the record from sysobjects:
>name,id,xtype,uid,info,status,base_schema_ver,rep linfo,pa
rent_obj,crdate,ftcatid,
>schema_ver,stats_schema_ver,type,userstat,sysstat ,indexde
l,refdate,version,deltri
>g,instrig,updtrig,seltrig,category,cache
>"Object_Access_Levels",1858821684,"U ",1,17,8451,272,0,0,
"07/12/2002
>02:09pm",0,272,0,"U ",1,115,0,"07/12/2002
02:09pm",0,,,,0,2560,0
>Does anyone have a clue how I can fix this problem?
>I am using SQL2K with SP3a.
>TIA,
>-Steve-
>
>.
>
Hi Mark,
Running: DBCC CHECKCATALOG ('MedMas') WITH NO_INFOMSGS
Returns this error:
[Table Corrupt: Object ID 1840725610 (object '1840725610') does not match between
'SYSCOLUMNS' and 'SYSOBJECTS']
Is this fixable without rebuilding the database?
Thanks,
-Steve-
"mark baekdal" <anonymous@.discussions.microsoft.com> wrote in message
news:26ebb01c46255$b2dbd4b0$a301280a@.phx.gbl...
You may want to run DBCC CHECKCATALOG to check the system
tables.
Mark Baekdal
www.dbghost.com - the only true Database Change Manager
for SQL Server.
|||BTW, I just checked the ID 1840725610, it doesn't belong the Object_Access_Levels
table. It belongs to a couple of params. I think this DB is really hosed!
-Steve-
"Steve Zimmelman" <sk_z@.psi_med.com> wrote in message
news:%23JR2N$oYEHA.1764@.TK2MSFTNGP10.phx.gbl...
Hi Mark,
Running: DBCC CHECKCATALOG ('MedMas') WITH NO_INFOMSGS
Returns this error:
[Table Corrupt: Object ID 1840725610 (object '1840725610') does not match between
'SYSCOLUMNS' and 'SYSOBJECTS']
Is this fixable without rebuilding the database?
Thanks,
-Steve-
"mark baekdal" <anonymous@.discussions.microsoft.com> wrote in message
news:26ebb01c46255$b2dbd4b0$a301280a@.phx.gbl...
You may want to run DBCC CHECKCATALOG to check the system
tables.
Mark Baekdal
www.dbghost.com - the only true Database Change Manager
for SQL Server.
|||Steve,
Any idea what error message(s) you were getting? If
error 2513, check SQL Books Online for steps to possibly
resolve the inconsistency. Please ensure you have a
backup or copy of the .mdf & .ldf before you do anything.
HTH
Darren Fuller

>--Original Message--
>Hi Mark,
>Running: DBCC CHECKCATALOG ('MedMas') WITH NO_INFOMSGS
>Returns this error:
>[Table Corrupt: Object ID 1840725610
(object '1840725610') does not match between
>'SYSCOLUMNS' and 'SYSOBJECTS']
>Is this fixable without rebuilding the database?
>Thanks,
>-Steve-
>"mark baekdal" <anonymous@.discussions.microsoft.com>
wrote in message
>news:26ebb01c46255$b2dbd4b0$a301280a@.phx.gbl...
>You may want to run DBCC CHECKCATALOG to check the system
>tables.
>Mark Baekdal
>www.dbghost.com - the only true Database Change Manager
>for SQL Server.
>
>.
>
|||After much wasted time, I restored an old copy of the db. I was under the
impression (apparently a false one) that SQL server didn't have these types
corruption problems.
Thanks everyone for your suggestions.
-Steve-
|||Your impression is not false, we don't have these types of corruption
problems.
However, hardware can and does introduce all manner of corruptions that
manifest themselves in various ways. I would check your NT event logs and
SQL errorlog for IO susbsystem errors. Before restoring from your backup, I
would have recommended running DBCC CHECKDB to check for other corruptions.
In future, to avoid wasting time, you should call Product Support who will
be able to help you pinpoint the problem very quickly.
Regards.
Paul Randal
Dev Lead, Microsoft SQL Server Storage Engine
This posting is provided "AS IS" with no warranties, and confers no rights.
"Steve Zimmelman" <sk_z@.psi_med.com> wrote in message
news:ermVPB6YEHA.1048@.tk2msftngp13.phx.gbl...
> After much wasted time, I restored an old copy of the db. I was under the
> impression (apparently a false one) that SQL server didn't have these
types
> corruption problems.
> Thanks everyone for your suggestions.
> -Steve-
>