利用ASP.NET 回存資料為HTML語法的時候,若是沒有特別處理會被誤判為有攻擊性的存檔
存檔時出現A potentially dangerous Request.Form value was detected from the client
狀況會如下圖顯示:
利用ASP.NET 回存資料為HTML語法的時候,若是沒有特別處理會被誤判為有攻擊性的存檔
存檔時出現A potentially dangerous Request.Form value was detected from the client
狀況會如下圖顯示:
如何解決在上傳檔案時遇到檔案過大的錯誤排解
ASP.NET讀取資料或上傳檔案時的預設檔案大小是4MB,因此會直接出現下面的情形
錯誤訊息如下:
Description: An unhandled exception occurred during the execution of the current web request. Please review the stack trace for more information about the error and where it originated in the code.
Exception Details: System.Web.HttpException: Maximum request length exceeded.
Source Error:
An unhandled exception was generated during the execution of the current web request. Information regarding the origin and location of the exception can be identified using the exception stack trace below. |
解決方法:
在Web.Config中加上以下資訊
<configuration>
<system.web>
<httpRuntime maxRequestLength="1048576" />
</system.web>
</configuration>
<system.webServer>
<security>
<requestFiltering>
<requestLimits maxAllowedContentLength="1073741824" />
</requestFiltering>
</security>
</system.webServer>
Windows10電腦用久了總是該清一清,尤其是看到C槽出現了紅色的一條,明明還有很足夠的空間,心裡就是不舒服
首先先來處理最常累積的暫存空間
-------------------------IE瀏覽器 可以清除的地方-----------------------
使用cmd執行或是powershell
上網瀏覽歷史
RunDll32.exe InetCpl.cpl, ClearMyTracksByProcess 1
上網產生的Cookies
RunDll32.exe InetCpl.cpl,ClearMyTracksByProcess 2
上網產生的Internet 臨時文件
RunDll32.exe InetCpl.cpl,ClearMyTracksByProcess 8
網頁上的填表記錄
RunDll32.exe InetCpl.cpl, ClearMyTracksByProcess 16-------------------------------個人暫存檔----------------------------------
手動刪除方式
路徑 C:\Users\你登入的帳號\AppData\Local\Temp
指令模式
Get-ChildItem C:\Users\你登入的帳號\AppData\Local\Temp -Recurse | Remove-Item -confirm:$false -force -Recurse -ErrorAction SilentlyContinue
手動刪除方式
Outlook 2010、Outlook2007 版本的路徑暫存檔
路徑 C:\Users\你登入的帳號\AppData\Local\Microsoft\Windows\INetCache\Content.Outlook\隨機產生的名稱
Outlook 2003版本的路徑暫存檔
路徑 C:\Users\你登入的帳號\AppData\Local\Microsoft\Windows\Temporary Internet Files\OLKFoldername
指令模式
Get-ChildItem 上述路徑 -Recurse | Remove-Item -Confirm:$false -force -Recurse
當少了SQL admin的時候,還是有些方法是可以執行我想要做到的事情
所以當我必須重作index的時候,可以利用指令的方式,搭配夜間排程來執行
1.首先將下面script存成檔案,命名為Execute_RebulidIndex.sql
利用EXCEL 想要記錄每天當天的日期 或者是 當下的時間 可以利用快速鍵完成
如果想要用鍵盤快速得到下面的樣式
有時候這種指令還是蠻好用的,可以一次找出那些TABLE使用量是最高的
語法如下:
select schema_name(tab.schema_id) + '.' + tab.name as [table],
cast(sum(spc.used_pages * 8)/1024.00 as numeric(36, 2)) as used_mb,
cast(sum(spc.total_pages * 8)/1024.00 as numeric(36, 2)) as allocated_mb
from sys.tables tab
inner join sys.indexes ind
on tab.object_id = ind.object_id
inner join sys.partitions part
on ind.object_id = part.object_id and ind.index_id = part.index_id
inner join sys.allocation_units spc
on part.partition_id = spc.container_id
group by schema_name(tab.schema_id) + '.' + tab.name
order by sum(spc.used_pages) desc
參考資料
https://dataedo.com/kb/query/sql-server/list-of-tables-by-their-size