小编Nea*_*son的帖子

如何查看SQL Server 2005事务日志文件

如何查看SQL Server事务日志文件(.trn)?

我希望能够在单个事务中查看trn文件.一些记录从数据库中删除,我需要知道何时,如何以及由谁.

谢谢Neal

编辑:我删除之前和之后的.bak文件,以及期间的.trn文件.

编辑(2010-11-16):详细讨论:http://www.sqlservercentral.com/Forums/Topic1019240-357-1.aspx

analysis sql-server-2005 transaction-log

5
推荐指数
1
解决办法
1万
查看次数

为什么我的StreamWriter响应输出在Excel中产生垃圾重音但在记事本中看起来很好?

我正在使用另一个Stack Overflow问题的技术将CSV文件写入Response输出以供用户打开/保存.该文件在记事本中看起来不错,但是当我在Excel中打开它时,重音字符是垃圾.我认为这与字符编码有关,所以我尝试手动将其设置为UTF-8(默认为StreamWriter).这是代码:

// This fills a list to enumerate - each record is one CSV line
List<FullRegistrationInfo> fullUsers = GetFullUserRegistrations();

context.Response.Clear();
context.Response.AddHeader("content-disposition",
                           "attachment; filename=registros.csv");
context.Response.ContentType = "text/csv";
context.Response.Charset = "utf-8";

using (StreamWriter writer = new StreamWriter(context.Response.OutputStream))
{
    for (int i = 0; i < fullUsers.Count(); i++)
    {
        // Get the record to process
        FullRegistrationInfo record = fullUsers[i];

        // If it's the first record then write header
        if (i == 0)
            writer.WriteLine(Encoding.UTF8.GetString(
                Encoding.UTF8.GetPreamble()) + 
                "User, …
Run Code Online (Sandbox Code Playgroud)

asp.net excel response character-encoding streamwriter

4
推荐指数
1
解决办法
5989
查看次数

如何判断html字符串在浏览器中是否显示为空?(C#/正则表达式?)

我有一个控件,会将一些html作为字符串返回给我.在把它放到屏幕上之前,我想知道它是否只是显示为空.

例如,控件可能会返回<p><br /></p>,当我使用C#测试string.Emtpy时,显然它不是 - 但屏幕上没有显示任何内容.

是否有正则表达式函数来测试html是否会在屏幕上显示任何文本?或者使用C# - 是否有任何函数来测试包含html的字符串,看它是否实际上包含除标签之外的任何内容?

干杯,我有点困惑如何在不写一些自定义解析器的情况下解决这个问题,这条道路我不想下去!

html c# regex string

2
推荐指数
1
解决办法
4421
查看次数