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

Çë½ÌSQLת»»×Ö·ûÎÊÌâ - .NET¼¼Êõ / ASP.NET

SQL code:

declare @pagecount int
declare @sql varchar(500)
set @pagecount=10
set @sql='select top '+cast(@pagecount as varchar(10))+' * from book order by [ID] desc'
exec (@sql)



Ö´Ðлᱨ´í¡°ÔÚ½« varchar Öµ 'select top 10 * from book order by [ID] desc' ת»»³ÉÊý¾ÝÀàÐÍ int ʱʧ°Ü¡£¡±

ÇëÎÊÕâÀïÔõôƴ×Ö·û£¿Èç¹û±íÃûÊDZäÁ¿ÇëÎÊÔõôƴд£¿
Ë­ÓÐSQLÆ´×Ö·ûµÄ×ÊÁÏ£¿·¢ÍøÖ·£¬Ð»Ð»
¸ÕÊÔÁËÏ£¬ÉÏÃæÕýÈ·£¬µ«ÏÂÃæÕâ¶ÎÖ´ÐеÄʱºò³öÎÊÌ⣿

´´½¨´æ´¢¹ý³Ì
SQL code:

create proc book_page3
@page int,@pagecount int
as
declare @sqls varchar(500)
declare @page2 int
declare @counts int
declare @sqlc int
declare @sqll int

select @counts=count(*) from book
set @sqlc=@counts/@pagecount+1
if @page<=@sqlc and @page<>0
begin
if @page<>1
begin
set @page2=@pagecount*(@page-1)
select top (@pagecount) * from book where [ID]<(select min(ID) from (select top (@page2) ID from book order by [ID] desc)b) order by [ID] desc
end

else
begin
set @page2=@pagecount*@page
select top (@pagecount) * from book order by [ID] desc
end
end
else
begin
set @sqll='select top '+cast(@pagecou


Ïà¹ØÎÊ´ð£º

ÇóÒ»¸öSQLÓï¾ä - MS-SQL Server / »ù´¡Àà

×Ö¶Î1,×Ö¶Î2.....×Ö¶ÎN,Status,ParentID
1,Name1....test1,1,99
1,Name1....test1,3,99
1,Name2....test2,1,101
1,Name2....test2,3,101
1,Name3....test3,2,101
1,Name1....test1,4,101
ÏëÒªµÄ½á¹ûÊÇ:
1,Na ......

AJAX ºǫ́Ôõôȡ²»µ½Ö± - .NET¼¼Êõ / ASP.NET

´úÂëÈçÏ Çë¸ßÊÖ Ö¸µãÏ лл
ajax_http.js
-------------
function getXMLHTTP() {
  var xmlhttp;
  if (window.ActiveXObject) {
  //IE
  try {
  ......

SQL·ÖÒ³ÓëOracle·ÖÒ³µÄÒÉÎÊ£¿ - Java / Web ¿ª·¢

ÕâÀïÏëÁ˽âÏ£¬¹ØÓÚSQL ServerÖзÖÒ³ºÍOracleÖзÖÒ³£»
ƽ³£Ð´Ó¦ÓóÌÐòµÄʱºò£¬±ÈÈçÓõÄÓïÑÔÊÇJava£¬ÓиöÁбíÒ³Ã棬ÐèÒª¶ÔÊý¾Ý·ÖÒ³ÏÔʾ£»
ÕâÀïÒª·ÖÒ³ÄѵÀ²»ÐèÒª½èÖúJava£¬¶øÖ±½ÓsqlÄÜÖªµÀ·ÖÒ³Âð£¬ÆðÂëÒ²Òª´«¸öÒ³Âë½ ......

¹ØÓÚSqlµÄÎÊÌâ - .NET¼¼Êõ / ASP.NET

½«Ò»¸ö²éѯÓï¾ä¸³¸øÒ»¸ö±äÁ¿£¬ÈçÏ£º
DECLARE @STR NVARCHAR(MAX)
SET @STR='SELECT * from SALE_PROD'
ÔõôÑù²ÅÄÜÖ´ÐÐËüÄØ£¿
Çë¸ßÊÖ£¬ÈÊÐÖ£¬ÏÀ½ã°ï°ïæ°¡


¶àл£¬¿ÉÒÔÀ²£¬¸ßÊÖ°¡

Ö±½ÓÖ´ÐоÍÐÐÁË

exec ......

Accessͨ¹ýSqlÓï¾ä´´½¨Êý¾Ý¿â - .NET¼¼Êõ / C#

ÔÚAccessµÄ²éѯÖÐÖ´ÐÐÏÂÃæµÄÓï¾ä,ÎÞЧ,ÌáʾÆÚ´ýselect ,updata ,...
CreateTble C=Answer N="»ØÌû±í"
(
  C=ID T="INTEGER" P=No M=No N="±àºÅ" Z=false,
  C=Ques ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ