textarea中的内容通过添加按钮添加到SQL数据库中
我定义了一个 textarea:
<tr bgcolor="#CCCCCC" align="center" valign="bottom">
<td align="right" valign="top" class="style1" >文章内容:</td>
<td width="83%" bgcolor="#FFFFFF" align="left">
<textarea cols="75" rows="6" style="width: 1000px; height: 576px"></textarea>
</td>
</tr>
<tr bgcolor="#abb8d6">
<td colspan="2" width="588" align="center" height="55">
<asp:Button ID="Button1" runat="server" Text="添加" onclick="Button1_Click" Width="55px" />
<asp:Button ID="Button2" runat="server" Text="取消" onclick="Button2_Click" Width="55px" />
</td>
</tr>
现在想通过“添加”按钮将textarea中的内容添加到指定的数据库中,该怎么办?
相关文档:
在这里,我所指的版本是指的2000,2005,2008这样的版本区别,而不是企业版,开发版这样的版本区别.从官方的说法来看,SQL Server是允许数据库从低版本向高版本恢复,但不支持高版本向低版本的恢复,如果我们用高版本的数据库在低版本的数据库引擎下恢复,会出现什么错误描述呢?
......
1.对查询进行优化,应尽量避免全表扫描,首先应考虑在 where 及 order by 涉及的列上建立索引。
2.应尽量避免在 where 子句中对字段进行 null 值判断,否则将导致引擎
放弃使用索引而进行全表扫描,如:
select id from t where num is null
可以在num上设置
默认值0,确保表中num列没有null值,然后这
样查询:
sel ......
SQL常用字符串函数
一、字符转换函数
1、ASCII()
返回字符表达式最左端字符的ASCII 码值。在ASCII()函数中,纯数字的字符串可不用‘’括起来,但含其它字符的字符串必须用‘’括起来使用,否则会出错。
2、CHAR()
将ASCII 码转换为字符。如果没有输入0 ~ 255 之间 ......
--测试数据
if OBJECT_ID('tb') is not null
drop table tb
go
CREATE TABLE tb(ID char(3),PID char(3),Name nvarchar(10))
INSERT tb SELECT '001',NULL ,'山东省'
UNION ALL SELECT '002','001','烟台市'
UNION ALL SELECT '004','002','招远市'
UNION ALL SELECT '003','001','青岛市'
UNION ALL SELECT '00 ......
Rebuild indexes online with SQL Server 2005
http://blogs.techrepublic.com.com/datacenter/?p=249
Online index rebuild
SQL Server 2005 introduces the ability to rebuild your indexes in an
online fashion so that other processes are able to access the table
while the rebuild is occurring. Because y ......