Showing posts with label web. Show all posts
Showing posts with label web. Show all posts

Monday, March 26, 2012

Recovering using the transaction log

I have a database hosted on a comercial web server
I can access it using SQL server Entreprise Manager
I have never backed the database up though i copy it
regularly.
Exactly how do you recover the database to an earlier point using the
Transaction Log and can it be done to recover 'Dropped' objects
Help gratefully received regards EarnieMost probably you have to revert to one of your older copies. You *might* be
able to use any of the
log reader tools out there, but as you never backed up the database, then mo
st probably the log
records needed to undo the modifications aren't around anymore in the transa
ction log files of the
database. See my article on the subject at:
http://www.karaszi.com/SQLServer/in...veral_times.asp
Tibor Karaszi, SQL Server MVP
http://www.karaszi.com/sqlserver/default.asp
http://www.solidqualitylearning.com/
http://www.sqlug.se/
"Earnie" <Earnie@.discussions.microsoft.com> wrote in message
news:A6434B02-D7BA-4E6D-ABD7-E5D177DBAF4F@.microsoft.com...
>I have a database hosted on a comercial web server
> I can access it using SQL server Entreprise Manager
> I have never backed the database up though i copy it
> regularly.
> Exactly how do you recover the database to an earlier point using the
> Transaction Log and can it be done to recover 'Dropped' objects
> Help gratefully received regards Earniesql

Friday, March 23, 2012

Recovering from Deadlocks: retrying the query

I'm having some deadlocking issues in my ASP.Net 2.0 web application with SQL Server 2000. One solution I've come across involves catching the the deadlock error (at the application level) and then retrying the query again, in the hopes that whatever was causing the deadlock is no longer locked.

I've tried to implement such a solution, where I catch the deadlock exception, then try to execute the same query again. Only now I'm getting a "The transaction is in doubt" exception.

So am I going about this wrong? Am I supposed to retry the entire transaction, or is valid to just try to redo the one query that it failed on? Is there some way around the transaction being in doubt?

You should determine the cause of the deadlock and correct your SQL code rather than retry mechanism. Retry mechanism can be complicated depending on what you are doing, whether you are in a transaction and so on. Deadlock typically means that you have access paths in your code that is not optimized and different for similar operations. Check out the following links on how to troubleshoot deadlocks:

http://msdn2.microsoft.com/en-us/library/ms177433.aspx

http://msdn2.microsoft.com/en-us/library/ms188246.aspx

http://msdn.microsoft.com/library/default.asp?url=/library/en-us/acdata/ac_8_con_7a_8i93.asp

sql

Friday, March 9, 2012

recover a pdf via Web services

Hi,

It's the first time that I use reporting services and web servcies. And I have some problems.

I have severals reporting services. These reports are simple text with some data. I have to call these reports by web services. The report have to receive a int as parameter.

And the report has to return a pdf and give it to the web service.

Can you help me please?

Thank you

Regards

Oups I forgot to ask the question.

Do you know how cal a report by a web servcie and is it possible to give a pdf file to a web service?

|||

ok,

I found the class ReportingService. But Visual studio doesn't recognize it. Is it because i put it in a web service? I search in alot of different sites and I have exactly the same code

|||You need to generate the Web Service proxy:
http://msdn2.microsoft.com/en-us/library/ms155134.aspx

Saturday, February 25, 2012

Records Duplicate when edited...?

Hi,

I have written a web application using dreamweaver MX, asp.net, and MSsql server 2005.

The problem I am having occurs when I attempt to edit a record. I have setup a datagrid with freeform fields so that the user can click on edit, make the required changes within the data grid then click update. The data is then saved to the database. All this was created using dreameaver and most of the code was automatically generated for me.

The problem is that, not everytime, but sometimes when I go to edit a record once I hit the update button to save the changes the record is duplicated 1 or more times. This doesnt happen everytime but when it does it duplicates the record between 1 and about 5 times. I have double checked everything but cannot find anything obvious that may be causing this issue.

Does anyone have any suggestions as to what I should look for? Is this a coding error or something wrong with MSsql? Any ideas?

Thanks in advance
-Mitch

If you provide the code, then it will be easier to give suggestions.