how can i get back the dropped table into my database?

Posted by Sudheep.grandhe under Sql Server on 12/2/2011 | Points: 10 | Views : 3689 | Status : [Member] | Replies : 7
Hi,

unfortunately i drop the table.how can i retrieve it back.

Best,
Sudheep.



Responses

Posted by: Sksingh on: 12/2/2011 [Member] Starter | Points: 25

Up
0
Down
Dont think possible to retrieve it back.. Until you have backup of database.

Regards,
Sunil

Sudheep.grandhe, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Sudheep.grandhe on: 12/2/2011 [Member] Starter | Points: 25

Up
0
Down
Hi,

I am having the backup of database.how can i proced for restore it

Best,
Sudheep.

Sudheep.grandhe, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Sksingh on: 12/2/2011 [Member] Starter | Points: 25

Up
0
Down
Hi,

First of all restore you backup with different DB name at same server and then you can import particular table to you final database ..


Regards,
Sunil

Sudheep.grandhe, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Sudheep.grandhe on: 12/2/2011 [Member] Starter | Points: 25

Up
0
Down
Hi,

i created the different databasename in the same server but it wont restore.
TITLE: Microsoft SQL Server Management Studio
------------------------------

Restore failed for Server 'MARS-104'. (Microsoft.SqlServer.Smo)

For help, click: http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&ProdVer=9.00.1399.00&EvtSrc=Microsoft.SqlServer.Management.Smo.ExceptionTemplates.FailedOperationExceptionText&EvtID=Restore+Server&LinkId=20476

------------------------------
ADDITIONAL INFORMATION:

System.Data.SqlClient.SqlError: The backup set holds a backup of a database other than the existing 'marsweb1' database. (Microsoft.SqlServer.Smo)

For help, click: http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&ProdVer=9.00.1399.00&LinkId=20476

------------------------------
BUTTONS:

OK
------------------------------


Best,
Sudheep.

Sudheep.grandhe, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Hmanjarawala on: 12/2/2011 [Member] Bronze | Points: 25

Up
0
Down
SQL Server keeps log for each deleted records. you can query these logs via 'fn_dblog' sql server function.

Select [RowLog Contents 0] FROM sys.fn_dblog(NULL, NULL) WHERE AllocUnitName = 'dbo.TableName' AND Context IN ( 'LCX_MARK_AS_GHOST', 'LCX_HEAP' ) AND Operation in ( 'LOP_DELETE_ROWS' )But this log is in Hex format. and you need to convert this Hex format to your actual data.Given below is the article will help you to recover the deleted records in the same way defined above.

http://raresql.com/2011/10/22/how-to-recover-deleted-data-from-sql-sever/


Himanshu Manjarawala
Sr. Software Engineer@AutomationAnywhere
http://fieredotnet.wordpress.com/

Sudheep.grandhe, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Sudheep.grandhe on: 12/3/2011 [Member] Starter | Points: 25

Up
0
Down
Hi,

I am drop the table not deleted.totally dropped the table the above query is working for drop.

Best,
Sudheep.

Sudheep.grandhe, if this helps please login to Mark As Answer. | Alert Moderator

Posted by: Sksamantaray on: 12/13/2011 [Member] Silver | Points: 25

Up
0
Down
Hi ,
While restoring check the .mdf and .ldf having correct name and path or not

Thanks,
Sanjay

Sudheep.grandhe, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response