
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-06-2009 12:35 PM
I accidentally deleted some tables and a view of sql, I needed the script to be able to recreate these databases without losing the data already entered.
You may paseis me the sql file to launch
For example, I get this error
System.Data.SqlClient.SqlException: Invalid object name 'web30repHDDFreeServers'.
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)
System.Exception: The DefaultView was requested but no tables yet exist.
at DreamweaverCtrls.DataSet.get_DefaultView()
Thanks
Labels:
- Labels:
-
Archive
3 REPLIES 3

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-13-2009 11:12 PM
Table : tblreports

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-06-2009 02:07 PM
Ok, thanks.
i execute this script and perfect.
I need change the name off reports, what is the table to change the name?
i execute this script and perfect.
I need change the name off reports, what is the table to change the name?

Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎02-06-2009 02:00 PM
CREATE VIEW dbo.web30repHDDFreeServers
AS
SELECT dbo.tblComputers.Computername AS Computer, dbo.tblOperatingsystem.Description, dbo.tblDiskdrives.Caption,
CAST(CAST(dbo.tblDiskdrives.Freespace AS bigint) / 1024 / 1024 AS numeric) AS Free, CAST(CAST(dbo.tblDiskdrives.Size AS bigint)
/ 1024 / 1024 AS numeric) AS [Total size], dbo.tblDiskdrives.Lastchanged AS [Last changed]
FROM dbo.tblComputers INNER JOIN
dbo.tblDiskdrives ON dbo.tblComputers.Computername = dbo.tblDiskdrives.Computername INNER JOIN
dbo.tblOperatingsystem ON dbo.tblComputers.Computername = dbo.tblOperatingsystem.Computername INNER JOIN
dbo.Web30repAllServers ON dbo.tblComputers.Computername = dbo.Web30repAllServers.Computername
WHERE (dbo.tblDiskdrives.DriveType = '3') AND (CAST(CAST(dbo.tblDiskdrives.Freespace AS bigint) / 1024 / 1024 AS numeric) < 1024) AND
(CAST(CAST(dbo.tblDiskdrives.Size AS bigint) / 1024 / 1024 AS numeric) <> 0)
ORDER BY CAST(CAST(dbo.tblDiskdrives.Freespace AS bigint) / 1024 / 1024 AS numeric), dbo.tblComputers.Computername, dbo.tblDiskdrives.Caption
