最近捣鼓了一下,效果就是这样:
图1:
![](https://images.cnblogs.com/cnblogs_com/cry/p2.jpg)
图2:
![](https://images.cnblogs.com/cnblogs_com/cry/p1.jpg)
ImageFileUpload.aspx:
<%
@ Page Language
=
"
C#
"
AutoEventWireup
=
"
true
"
CodeFile
=
"
ImageFileUpload.aspx.cs
"
Inherits
=
"
ImageFileUpload
"
%>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
<!
DOCTYPE html PUBLIC
"
-//W3C//DTD XHTML 1.0 Transitional//EN
"
"
http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd
"
>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
<
html xmlns
=
"
http://www.w3.org/1999/xhtml
"
>
<
head runat
=
"
server
"
>
<
title
>
图片保存和显示
</
title
>
</
head
>
<
body
>
<
form id
=
"
Form2
"
enctype
=
"
multipart/form-data
"
runat
=
"
server
"
>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
<
asp:Table ID
=
"
Table1
"
Runat
=
"
server
"
Width
=
"
39%
"
BorderWidth
=
"
1
"
BackColor
=
"
Beige
"
>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
<
asp:TableRow runat
=
"
server
"
>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
<
asp:TableCell ColumnSpan
=
"
2
"
BackColor
=
"
Red
"
runat
=
"
server
"
>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
<
asp:Label ID
=
"
Label1
"
Font
-
size
=
"
12px
"
ForeColor
=
"
White
"
font
-
bold
=
"
True
"
Runat
=
"
server
"
Text
=
"
添加
"
Font
-
Names
=
"
verdana
"
/>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
</
asp:TableCell
>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
</
asp:TableRow
>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
<
asp:TableRow runat
=
"
server
"
>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
<
asp:TableCell HorizontalAlign
=
"
Right
"
runat
=
"
server
"
><
asp:Label ID
=
"
Label2
"
Font
-
size
=
"
12px
"
Runat
=
"
server
"
Text
=
"
名字
"
Font
-
Names
=
"
verdana
"
/></
asp:TableCell
>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
<
asp:TableCell runat
=
"
server
"
><
asp:TextBox id
=
"
txtPersonName
"
Runat
=
"
server
"
/></
asp:TableCell
>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
</
asp:TableRow
>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
<
asp:TableRow runat
=
"
server
"
>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
<
asp:TableCell HorizontalAlign
=
"
Right
"
runat
=
"
server
"
><
asp:Label ID
=
"
Label3
"
Font
-
size
=
"
12px
"
Runat
=
"
server
"
Text
=
"
Email
"
Font
-
Names
=
"
verdana
"
/></
asp:TableCell
>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
<
asp:TableCell runat
=
"
server
"
><
asp:TextBox id
=
"
txtPersonEmail
"
Runat
=
"
server
"
/></
asp:TableCell
>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
</
asp:TableRow
>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
<
asp:TableRow runat
=
"
server
"
>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
<
asp:TableCell HorizontalAlign
=
"
Right
"
runat
=
"
server
"
><
asp:Label ID
=
"
Label4
"
Font
-
size
=
"
12px
"
Runat
=
"
server
"
Text
=
"
性别
"
Font
-
Names
=
"
verdana
"
/></
asp:TableCell
>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
<
asp:TableCell runat
=
"
server
"
>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
<
asp:RadioButton GroupName
=
"
sex
"
Font
-
Size
=
"
12px
"
Text
=
"
男性
"
ID
=
"
sexMale
"
Runat
=
"
server
"
Checked
=
"
true
"
/>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
<
asp:RadioButton GroupName
=
"
sex
"
Font
-
Size
=
"
12px
"
Text
=
"
女性
"
ID
=
"
sexFeMale
"
Runat
=
"
server
"
/>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
</
asp:TableCell
>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
</
asp:TableRow
>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
<
asp:TableRow runat
=
"
server
"
>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
<
asp:TableCell HorizontalAlign
=
"
Right
"
runat
=
"
server
"
><
asp:Label ID
=
"
Label5
"
Font
-
size
=
"
12px
"
Runat
=
"
server
"
Text
=
"
生日
"
Font
-
Names
=
"
verdana
"
/></
asp:TableCell
>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
<
asp:TableCell runat
=
"
server
"
><
asp:TextBox id
=
"
txtPersonDob
"
runat
=
"
server
"
/></
asp:TableCell
>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
</
asp:TableRow
>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
<
asp:TableRow runat
=
"
server
"
>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
<
asp:TableCell HorizontalAlign
=
"
Right
"
runat
=
"
server
"
><
asp:Label ID
=
"
Label6
"
Font
-
size
=
"
12px
"
Runat
=
"
server
"
Text
=
"
图片
"
Font
-
Names
=
"
verdana
"
/></
asp:TableCell
>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
<
asp:TableCell runat
=
"
server
"
><
input type
=
"
file
"
id
=
"
PersonImage
"
runat
=
"
server
"
/></
asp:TableCell
>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
</
asp:TableRow
>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
<
asp:TableRow runat
=
"
server
"
>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
<
asp:TableCell ColumnSpan
=
"
2
"
HorizontalAlign
=
"
Center
"
runat
=
"
server
"
>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
<
asp:Button ID
=
"
Button1
"
Text
=
"
添加
"
OnClick
=
"
AddPerson
"
runat
=
"
server
"
/>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
</
asp:TableCell
>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
</
asp:TableRow
>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
</
asp:Table
>
<
br
/>
<
table
>
<
tr
>
<
td align
=
"
left
"
valign
=
"
top
"
style
=
"
width: 181px
"
>
<
asp:Label ID
=
"
Label_Message
"
runat
=
"
server
"
Font
-
Size
=
"
10pt
"
></
asp:Label
></
td
>
<
td style
=
"
width: 7px
"
>
</
td
>
<
td align
=
"
left
"
style
=
"
width: 18px
"
valign
=
"
top
"
>
</
td
>
</
tr
>
<
tr
>
<
td style
=
"
width: 181px;
"
align
=
"
left
"
valign
=
"
top
"
>
<
asp:GridView ID
=
"
GridView1
"
runat
=
"
server
"
AutoGenerateColumns
=
"
False
"
CellPadding
=
"
4
"
DataKeyNames
=
"
PersonID
"
DataSourceID
=
"
SqlDataSource_SelectImage
"
ForeColor
=
"
#333333
"
OnSelectedIndexChanged
=
"
GridView1_SelectedIndexChanged
"
Font
-
Size
=
"
10pt
"
Width
=
"
200px
"
BackColor
=
"
#FFE0C0
"
>
<
FooterStyle BackColor
=
"
#507CD1
"
Font
-
Bold
=
"
True
"
ForeColor
=
"
White
"
/>
<
Columns
>
<
asp:TemplateField HeaderText
=
"
序号
"
InsertVisible
=
"
False
"
SortExpression
=
"
PersonID
"
>
<
EditItemTemplate
>
<
asp:Label ID
=
"
Label1
"
runat
=
"
server
"
Text
=
'
<%# Eval("PersonID") %>
'
></
asp:Label
>
</
EditItemTemplate
>
<
ItemTemplate
>
<
asp:Label ID
=
"
Label1
"
runat
=
"
server
"
Text
=
'
<%# Bind("PersonID") %>
'
></
asp:Label
>
</
ItemTemplate
>
<
HeaderStyle Width
=
"
35px
"
/>
</
asp:TemplateField
>
<
asp:BoundField DataField
=
"
PersonName
"
HeaderText
=
"
名字
"
SortExpression
=
"
PersonName
"
/>
<
asp:BoundField DataField
=
"
PersonImageType
"
HeaderText
=
"
图片类型
"
SortExpression
=
"
PersonImageType
"
/>
<
asp:CommandField ShowSelectButton
=
"
True
"
>
<
ItemStyle Width
=
"
30px
"
/>
</
asp:CommandField
>
</
Columns
>
<
RowStyle BackColor
=
"
#EFF3FB
"
/>
<
EditRowStyle BackColor
=
"
#2461BF
"
/>
<
SelectedRowStyle BackColor
=
"
#D1DDF1
"
Font
-
Bold
=
"
True
"
ForeColor
=
"
#333333
"
/>
<
PagerStyle BackColor
=
"
#2461BF
"
ForeColor
=
"
White
"
HorizontalAlign
=
"
Center
"
/>
<
HeaderStyle BackColor
=
"
Red
"
Font
-
Bold
=
"
True
"
ForeColor
=
"
White
"
/>
<
AlternatingRowStyle BackColor
=
"
White
"
/>
</
asp:GridView
>
</
td
>
<
td style
=
"
width: 7px; height: 180px;
"
>
</
td
>
<
td align
=
"
left
"
style
=
"
width: 18px; height: 180px;
"
valign
=
"
top
"
>
<
asp:Image ID
=
"
Image_Show
"
runat
=
"
server
"
/></
td
>
</
tr
>
<
tr
>
<
td style
=
"
width: 181px
"
>
</
td
>
<
td style
=
"
width: 7px
"
>
</
td
>
<
td style
=
"
width: 18px
"
>
</
td
>
</
tr
>
<
tr
>
<
td style
=
"
width: 181px; height: 21px;
"
>
</
td
>
<
td style
=
"
width: 7px; height: 21px;
"
>
</
td
>
<
td style
=
"
width: 18px; height: 21px;
"
>
</
td
>
</
tr
>
</
table
>
<
asp:SqlDataSource ID
=
"
SqlDataSource_SelectImage
"
runat
=
"
server
"
ConnectionString
=
"
<%$ ConnectionStrings:ImageSelect_ConnectionString %>
"
SelectCommand
=
"
SELECT PersonID, PersonName, PersonImageType FROM Person
"
></
asp:SqlDataSource
>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
</
form
>
</
body
>
</
html
>
ImageFileUpload.aspx.cs:
using
System;
using
System.Data;
using
System.Configuration;
using
System.Collections;
using
System.Web;
using
System.Web.Security;
using
System.Web.UI;
using
System.Web.UI.WebControls;
using
System.Web.UI.WebControls.WebParts;
using
System.Web.UI.HtmlControls;
using
System.Data.SqlClient;
using
System.IO;
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
public
partial
class
ImageFileUpload : System.Web.UI.Page
![ExpandedBlockStart.gif](https://www.cnblogs.com/Images/OutliningIndicators/ExpandedBlockStart.gif)
{
protected void Page_Load(object sender, EventArgs e)
![ExpandedSubBlockStart.gif](https://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockStart.gif)
{
![InBlock.gif](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
}
![InBlock.gif](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
![InBlock.gif](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
![InBlock.gif](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
![InBlock.gif](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
![InBlock.gif](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
protected void AddPerson(object sender, EventArgs e)
![ExpandedSubBlockStart.gif](https://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockStart.gif)
{
int intImageSize;
string strImageType;
Stream ImageStream;
![InBlock.gif](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
intImageSize = PersonImage.PostedFile.ContentLength;
ImageStream = PersonImage.PostedFile.InputStream;
strImageType = PersonImage.PostedFile.ContentType;
Byte[] ImageContent = new Byte[intImageSize];
int intStatus;
intStatus = ImageStream.Read(ImageContent, 0, intImageSize);
![InBlock.gif](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
//string ConnStr = System.Configuration.ConfigurationSettings.AppSettings["Lw_SqlConnectString"];
string ConnStr = "Data Source=127.0.0.1;Initial Catalog=Pfrmis_TZXY;User ID=sa";
SqlConnection myConnection=new SqlConnection(ConnStr);
SqlCommand myCommand=new SqlCommand("sp_person_isp", myConnection);
myCommand.CommandType = CommandType.StoredProcedure;
![InBlock.gif](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
SqlParameter prmEmail=new SqlParameter("@PersonEmail", SqlDbType.VarChar, 255);
![InBlock.gif](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
prmEmail.Value = txtPersonEmail.Text;
myCommand.Parameters.Add(prmEmail);
![InBlock.gif](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
SqlParameter prmName=new SqlParameter("@PersonName", SqlDbType.VarChar, 255);
![InBlock.gif](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
prmName.Value = txtPersonName.Text;
myCommand.Parameters.Add(prmName);
![InBlock.gif](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
SqlParameter prmSex =new SqlParameter("@PersonSex", SqlDbType.Char, 1);
if (sexMale.Checked)
![ExpandedSubBlockStart.gif](https://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockStart.gif)
{
prmSex.Value = "M";
}
else
![ExpandedSubBlockStart.gif](https://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockStart.gif)
{
prmSex.Value = "F";
}
myCommand.Parameters.Add(prmSex);
![InBlock.gif](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
SqlParameter prmPersonDOB= new SqlParameter("@PersonDOB", SqlDbType.DateTime);
![InBlock.gif](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
prmPersonDOB.Value = txtPersonDob.Text;
![InBlock.gif](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
myCommand.Parameters.Add(prmPersonDOB);
![InBlock.gif](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
SqlParameter prmPersonImage =new SqlParameter("@PersonImage", SqlDbType.Image);
![InBlock.gif](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
prmPersonImage.Value = ImageContent;
![InBlock.gif](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
myCommand.Parameters.Add(prmPersonImage);
![InBlock.gif](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
SqlParameter prmPersonImageType =new SqlParameter("@PersonImageType", SqlDbType.VarChar, 255);
![InBlock.gif](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
prmPersonImageType.Value = strImageType;
![InBlock.gif](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
myCommand.Parameters.Add(prmPersonImageType);
![InBlock.gif](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
try
![ExpandedSubBlockStart.gif](https://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockStart.gif)
{
myConnection.Open();
myCommand.ExecuteNonQuery();
![InBlock.gif](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
myConnection.Close();
![InBlock.gif](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
Response.Write("添加成功!");
![InBlock.gif](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
}
catch(SqlException SQLexc)
![ExpandedSubBlockStart.gif](https://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockStart.gif)
{
Response.Write("插入失败,错误如下: " + SQLexc.ToString());
}
![InBlock.gif](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
![InBlock.gif](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
}
![InBlock.gif](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
protected void GridView1_SelectedIndexChanged(object sender, EventArgs e)
![ExpandedSubBlockStart.gif](https://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockStart.gif)
{
![InBlock.gif](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
// Session["id"] = "";
Label lbl1;
lbl1 = (Label)GridView1.SelectedRow.Cells[0].FindControl("Label1");
![InBlock.gif](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
Label_Message.Text ="你选择的图片是:"+lbl1.Text;
Session["id"] = lbl1.Text;
Image_Show.ImageUrl = "ImageShow.aspx";
}
}
ImageShow.aspx:(显示图片)
<%
@ Page Language
=
"
C#
"
AutoEventWireup
=
"
true
"
CodeFile
=
"
ImageShow.aspx.cs
"
Inherits
=
"
ImageShow
"
%>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
<!
DOCTYPE html PUBLIC
"
-//W3C//DTD XHTML 1.0 Transitional//EN
"
"
http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd
"
>
![None.gif](https://www.cnblogs.com/Images/OutliningIndicators/None.gif)
<
html xmlns
=
"
http://www.w3.org/1999/xhtml
"
>
<
head runat
=
"
server
"
>
<
title
>
无标题页
</
title
>
</
head
>
<
body
>
<
form id
=
"
form1
"
runat
=
"
server
"
>
<
div
>
</
div
>
</
form
>
</
body
>
</
html
>
ImageShow.aspx.cs:
using
System;
using
System.Data;
using
System.Configuration;
using
System.Collections;
using
System.Web;
using
System.Web.Security;
using
System.Web.UI;
using
System.Web.UI.WebControls;
using
System.Web.UI.WebControls.WebParts;
using
System.Web.UI.HtmlControls;
using
System.Data.SqlClient;
public
partial
class
ImageShow : System.Web.UI.Page
![ExpandedBlockStart.gif](https://www.cnblogs.com/Images/OutliningIndicators/ExpandedBlockStart.gif)
{
protected void Page_Load(object sender, EventArgs e)
![ExpandedSubBlockStart.gif](https://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockStart.gif)
{
//连接数据库的第一种方法
SqlConnection myConnection = new SqlConnection(ConfigurationManager.AppSettings["Lw_SqlConnectString"]);
![InBlock.gif](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
//连接数据库的第二种方法
//SqlConnection myConnection = new SqlConnection("Data Source=.;Initial Catalog=Tcis_shrl;User Id=sa;Password=;");
if (Session["id"] == null)
![ExpandedSubBlockStart.gif](https://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockStart.gif)
{
![InBlock.gif](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
}
else
![ExpandedSubBlockStart.gif](https://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockStart.gif)
{
string sql = "Select PersonImage from Person Where PersonID=";
SqlCommand myCommand = new SqlCommand(sql + Session["id"].ToString().Trim(), myConnection);
try
![ExpandedSubBlockStart.gif](https://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockStart.gif)
{
myConnection.Open();
SqlDataReader myDataReader;
myDataReader = myCommand.ExecuteReader(CommandBehavior.CloseConnection);
if (myDataReader.Read())
![ExpandedSubBlockStart.gif](https://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockStart.gif)
{
Response.Clear();
![InBlock.gif](https://www.cnblogs.com/Images/OutliningIndicators/InBlock.gif)
// Response.ContentType = "image/pjpeg";//可有可无
Response.BinaryWrite((byte[])myDataReader["PersonImage"]);
}
myConnection.Close();
}
catch (SqlException SQLexc)
![ExpandedSubBlockStart.gif](https://www.cnblogs.com/Images/OutliningIndicators/ExpandedSubBlockStart.gif)
{
Response.Write(SQLexc);
}
Response.End();
}
}
}
最后一个存储过程:
Drop Table Person
Go
Create Table Person
(
PersonID Int Identity,
PersonEmail Varchar(255),
PersonName Varchar(255),
PersonSex Char(1),
PersonDOB DateTime,
PersonImage Image,
PersonImageType Varchar(255)
)
Drop Proc sp_person_isp
Go
Create Proc sp_person_isp
@PersonEmail Varchar(255),
@PersonName Varchar(255),
@PersonSex Char(1),
@PersonDOB DateTime,
@PersonImage Image,
@PersonImageType Varchar(255)
As
Begin
Insert into Person
(PersonEmail, PersonName, PersonSex,
PersonDOB, PersonImage, PersonImageType)
Values
(@PersonEmail, @PersonName, @PersonSex,
@PersonDOB, @PersonImage, @PersonImageType)
End
Go