摘要: ---------------------- Windows Phone 7手机开发、.Net培训、期待与您交流! ----------------------SQL UNION 操作符UNION 操作符用于合并两个或多个 SELECT 语句的结果集。请注意,UNION 内部的 SELECT 语句必须拥有相同数量的列。列也必须拥有相似的数据类型。同时,每条 SELECT 语句中的列的顺序必须相同。SQL UNION 语法SELECT column_name(s) FROM table_name1UNIONSELECT column_name(s) FROM table_name2注释:默认地, 阅读全文
posted @ 2011-12-12 19:48 笑木凡尘 阅读(129) 评论(0) 推荐(0)
摘要: ---------------------- Windows Phone 7手机开发、.Net培训、期待与您交流! ----------------------using System;using System.Collections.Generic;using System.ComponentModel;using System.Data;using System.Drawing;using System.Linq;using System.Text;using System.Windows.Forms;using System.IO;using System.Data.SqlClient; 阅读全文
posted @ 2011-12-12 19:22 笑木凡尘 阅读(179) 评论(0) 推荐(0)
摘要: ---------------------- Windows Phone 7手机开发、.Net培训、期待与您交流! ----------------------namespace winform1{ public partial class Form1 : Form { public Form1() { InitializeComponent(); }//将错误次数变为零 public void ResetErrorTimes() { using (SqlConnection conn = new SqlConnection(@"Data Source=.\sqlexpress;at 阅读全文
posted @ 2011-12-10 15:49 笑木凡尘 阅读(218) 评论(0) 推荐(0)
摘要: ---------------------- Windows Phone 7手机开发、.Net培训、期待与您交流! ----------------------using System;using System.Collections.Generic;using System.Linq;using System.Text;using System.Data.SqlClient;namespace OneDay4{ class Program { static void Main(string[] args) { Console.WriteLine("请输入用户名:"); s 阅读全文
posted @ 2011-12-10 14:11 笑木凡尘 阅读(230) 评论(0) 推荐(0)
摘要: ---------------------- Windows Phone 7手机开发、.Net培训、期待与您交流! ----------------------练习:创建一张表,记录电话呼叫员的工作流水,记录呼叫员编号、对方号码、通话开始时间、通话结束时间。建表、插数据等最后都自己写sql语句。Create table T_CallRecord( Id int primary key, Nchar(10) CallerNumber not null, Nvarchar(50) TelNum, Datetime StartDateTime, Datetime EndDateTime,)插入数据: 阅读全文
posted @ 2011-12-10 13:12 笑木凡尘 阅读(307) 评论(0) 推荐(0)