|
|
|
|
俵ÀÌ / 2001-02-15 / ¿ÀÈÄ 2:44:25 / 203.255.3.190
Á¶È¸¼ö : 127
|
[Áú¹®] ÇÏ·ç°¡ Áö³ ÀÚ·á´Â Áö¿ï·Á°í Çϴµ¥ À߾ȵų׿ä |
> ÇÏ·ç°¡ Áö³ ÀÚ·á´Â Áö¿ï·Á°í Çϴµ¥ À߾ȵų׿ä
> Á» µµ¿ÍÁÖ¼¼¿ä^^俵ÀÌ´Ô!
> ¿Ö ¾ÈµÅÁã??????
>
> ===============================================
> Set db = Server.CreateObject("ADODB.Connection")
> db.Open("DSN=ddd;uid=sa;PWD=;")
>
>
> ydday = datediff(d,1,getdate())
> 'ydday = now()-1
>
> SQL = "SELECT * FROM mytable where idate like ydday"
>
>
> Set Rs = Server.CreateObject("ADODB.Recordset")
>
> Rs.Open SQL,Db,1
>
>
> If Not Rs.Eof Then
> Do Until Rs.Eof
>
> DelSellSql = "delete mytable where number = " & number
>
> Db.Execute DelSellSql
> Rs.MoveNext
> Loop
>
> End If
> Rs.Close
> Set Rs = Nothing
>
> ============================================
-----------------------------------------------------------
³¯Â¥¸¦ µ¥ÀÌŸÇüÀ¸·Î Çϼ̳ª¿ä?
Àú´Â µ¥ÀÌŸÇüÀ¸·Î ÇØ º»ÀûÀÌ ¾ø¾î¼ Á¤È®È÷´Â ¸ð¸£°Ú³×¿ä...
µ¥ÀÌŸÇüÀ¸·Î ÇßÀ» °æ¿ì¿¡´Â »ç¿ëÇÏ´Â ¹æ¹ýÀÌ Æ²¸®°Å´ø¿ä...
µ¥ÀÌŸÇüÀÇ °æ¿ì Ãâ·ÂÇßÀ» °æ¿ì¿¡ 2000³â 2¿ù 15ÀÏÀ̶ó°í ³ª¿À´õ¶óµµ
½ÇÁ¦·Î 2000³â 2¿ù 15ÀÏÀ̶ó´Â °ªÀÌ µé¾î ÀÖ´Â °ÍÀÌ ¾Æ´Ï¶ó
Ư¼öÇÑ ¼ýÀÚÇüÅ·ΠÀúÀåµÇ¾î Àִ°ÍÀ¸·Î ¾Ë°í ÀÖ½À´Ï´Ù.
±×·¯´Ï like °°Àº°É·Î select ÇÒ ¼ö°¡ ¾ø°ÚÁö¿ä...
±×¸®°í vb¿¡´Â getdate()¶ó´Â ÇÔ¼ö°¡ ¾ø´Â°É·Î ¾Ð´Ï´Ù.
getdate()´Â sql¿¡¼ Áö¿øÇÏ´Â ÇÔ¼ö°Å´ø¿ä...
Áï sql ¹®Àå¿¡´Â ¾µ ¼ö ÀÖÁö¸¸ vb ÇÔ¼ö·Î´Â »ç¿ëÇÒ ¼ö°¡ ¾ø½À´Ï´Ù.
dateÇüÀ¸·Î ÇÏ´Â ¹æ¹ýÀ» ã¾Æ º¸½Ã´Â °ÍÀÌ ÁÁÀ» °Í °°½À´Ï´Ù.
¾Æ¸¶ select ÇÏÁö ¾Ê°í ¹Ù·Î delete ÇϽǶ§ whereÀý¿¡¼ Á¶°Ç¸¸ Àß ÁÖ¸é
»èÁ¦ÇÏ½Ç ¼ö ÀÖÀ»°Ì´Ï´Ù....
Á¤È®ÇÑ ´äº¯ ¸ø µå·Á¼ Á˼ÛÇÕ´Ï´Ù...
Á» ¹Ùºü¼¿ä... Á¦°¡ ã¾Æ º¼ ½Ã°£ÀÌ ¾ø³×¿ä...
|
|
|
|