Ò׽ؽØÍ¼Èí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

c# ²Ù×÷mssqlÊý¾Ý¿â º¬Óдø²ÎÊýsqlÓï¾äÔËÐÐ

<?xml version="1.0" encoding="utf-8"?>
<configuration>
 <appSettings>
  <add key="Default" value="Default" />
 </appSettings>
 <connectionStrings>
  <add name="Default" connectionString="Data Source=192.168.1.197;User ID=diamond;Password=88888888;Initial Catalog=EmailAnalyse" providerName="System.Data.SqlClient" />
 </connectionStrings>
</configuration>
using System;
using System.Data;
using System.Configuration;
using System.Web;
using System.Data.SqlClient;
using System.Collections.Generic;
using System.Text;
namespace OfficeOutlook
{
    /// <summary>
    ///DataBase µÄժҪ˵Ã÷
    /// </summary>
    public class DataBase
    {
        protected SqlConnection BaseSqlConnection = new SqlConnection();//Á¬½Ó¶ÔÏó
        protected SqlCommand BaseSqlCommand = new SqlCommand();  //ÃüÁî¶ÔÏó
        public DataBase()
        {
            //
            // TODO: ÔÚ´Ë´¦Ìí¼Ó¹¹Ô캯ÊýÂß¼­
            //
        }
        protected void OpenConnection()
        {
            if (BaseSqlConnection.State == ConnectionState.Closed)  //Á¬½ÓÊÇ·ñ¹Ø±Õ
                try
                {
           &nb


Ïà¹ØÎĵµ£º

ÕÒЩ²»´íµÄsqlÃæÊÔÌâ(1)

Student(S#,Sname,Sage,Ssex) ѧÉú±í
Course(C#,Cname,T#) ¿Î³Ì±í
SC(S#,C#,score) ³É¼¨±í
Teacher(T#,Tname) ½Ìʦ±í
ÎÊÌ⣺
1¡¢²éѯ“001”¿Î³Ì±È“002”¿Î³Ì³É¼¨¸ßµÄËùÓÐѧÉúµÄѧºÅ£»
  select a.S# from (select s#,score from SC where C#='001') a,(select s#,score
  fr ......

sqlÓÅ»¯34Ìõ

ÎÒÃÇÒª×öµ½²»µ«»áдSQL,»¹Òª×öµ½Ð´³öÐÔÄÜÓÅÁ¼µÄSQL,ÒÔÏÂΪ±ÊÕßѧϰ¡¢ÕªÂ¼¡¢²¢»ã×ܲ¿·Ö×ÊÁÏÓë´ó¼Ò·ÖÏí£¡
£¨1£©      Ñ¡Ôñ×îÓÐЧÂʵıíÃû˳Ðò(Ö»ÔÚ»ùÓÚ¹æÔòµÄÓÅ»¯Æ÷ÖÐÓÐЧ)£º
ORACLE µÄ½âÎöÆ÷°´ÕÕ´ÓÓÒµ½×óµÄ˳Ðò´¦Àífrom×Ó¾äÖеıíÃû£¬from×Ó¾äÖÐдÔÚ×îºóµÄ±í(»ù´¡±í driving table)½«±»×îÏÈ´¦Àí£¬ÔÚfrom× ......

hibernate sql ²Ù×÷

@SuppressWarnings("unchecked")
    public List<ZxFunction> selectFunctionParentByUserId(final int userId) {
        try {
            final String sql = "select *  from zx_function ......

SQL Server 2005 ÎÞ·¨É¾³ýÊý¾Ý¿â×÷Òµ

Óöµ½MS SQL Server 2005 ÎÞ·¨É¾³ýÊý¾Ý¿â×÷Òµ¡£
¡¡¡¡Ê×ÏÈ£¬ÒÔsaÕË»§µÇ¼£¬²é¿´ÒÔÏÂ2¸ö±íµÄÊý¾Ý£¬Èç¹û²»Îª¿Õ¾ÍÓÐÎÊÌâ¡£
¡¡¡¡Sql´úÂë
¡¡¡¡select¡¡*¡¡from¡¡msdb.dbo.sysmaintplan_subplans
¡¡¡¡select¡¡*¡¡from¡¡msdb.dbo.sysmaintplan_log
¡¡¡¡Èç¹û²»Îª¿Õ£¬Ö´ÐÐÒÔϲÙ×÷£¬»ù±¾Éϲ»Óÿ¼ÂÇɾ³ýÄÄÒ»Ìõ¼Ç¼£¬ÓÐÎÊÌâµÄ×÷Òµ¾Í ......

ÓÃSHELLµÄÑ­»·ÅúÁ¿Ö´ÐÐSQLÓï¾ä

--kshϵÄÒ»¸öWHILE Ñ­»·µÄÀý×Ó
integer i=1
while ((i<67))
do 
  pirnt $i
  i=i+1
done
--ksh ÏÂÒ»¸öFORÑ­»·µÄÀý×Ó
for i in `cat listdate.txt`
do
  echo "Ö´ÐÐ $i "
done
--- date.pl ÓÃÓÚÉú³ÉÒ»¸öʱ¼ä¶ÎÎļþ
#!/usr/local/bin/perl
use DBI;
if($#ARGV<1)
 {
&nbs ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ