- 浏览: 33666 次
- 性别:
- 来自: 山东
-
最新评论
文章列表
据查询随机排序一般都使用newid()来实现,数据量少时还可以,当达到上百万的数据量时,页面查询起来大约有4秒多,而使用新方式:where 0.01 >= CAST(CHECKSUM(NEWID(), id) & 0x7fffffff AS float) / CAST (0x7fffffff AS int)方式,查询只需几毫秒,在体验方面会提升很多
DOM Core常用部分
- 博客分类:
- 代码
DOM方法创建节点:createElement(),createTextNode()复制节点:cloneNode()插入节点:appendChild(),insertBefore删除节点:removeChild()替换节点:replaceChild()查找节点:getAttribute(),getElementById(),getElementsByTagName,hasChildNodes设置节点属性:setAttribute()
DOM属性节点的属性:nodeName,nodeType,nodeValue遍历节点树:childNodes,firstChild,lastChild, ...
SELECT
表名 = CASE WHEN A.COLORDER=1 THEN D.NAME ELSE '' END,
表說明 = CASE WHEN A.COLORDER=1 THEN ISNULL(F.VALUE,'') ELSE '' END,
欄位序號 = A.COLORDER,
欄位名 = A.NAME,
標識 = CASE WHEN COLUMNPROPERTY( A.ID,A.NAME,'ISIDENTITY')=1 THEN '√'ELSE '' END,
主鍵 = CASE WHEN EXISTS(SEL ...
This can happen if the owner of jmxremote.password is not the same as the current user (e.g. ownership is set to a group of users, like “Administrators”):To check this, right click on the file, select “Properties”, switch to the “Security” tab, click on “Advanced”, switch to the tab “Owner”, select y ...
首先下载ffmpeg解压
建立一个bat文件
start
E:/ffmpeg/bin/ffmpeg.exe -i %1 -ss 20 -vframes 1 -r 1 -ac 1 -ab 2 -s 160*120 -f image2 %2
exit
说明下使用红色吧标记的意义
E:/ffmpeg/bin/ffmpeg.exe ffmpeg的路径
%1 %2 和C语言有点相似是为传参数保留位置
20 要截取多少秒后的图片
打开MyEclipse,建立一个工程 ,以及一个java文件
package tes ...
在处理大数据量的时候,经常遇到堆栈溢出的异常java.lang.OutOfMemoryError: Java heap space
,主要是由于tomcat默认分配的内存为64M,当程序占用的内存大于64M时,就会报堆栈溢出溢出,可通过配置tomcat默认分配内存的大小解决,具体设置如下:
1、打开myeclipse选项,window->preferences
2、找到 MyEclipse Enterprise
Workbench->Servers->Tomcat->Tomcat 6.X->JDK 节点
3、在又侧 ...
EXEC master..xp_cmdshell 'bcp "我的SQL语句" queryout "文件的绝对路径" -c -S "(local)" -U "用户名" -P "密码"'
SQL Server 外围应用配置器需将 功能的外围应用配置 中 xp_cmdshell 开启为应用
import java.text.ParseException;
import java.text.SimpleDateFormat;
public class JavaTest {
/**
* @param args
* @throws ParseException
*/
public static void main(String[] args) throws ParseException {
// TODO Auto-generated method stub
SimpleDateFormat df = new Simple ...
一.ehcache主要是对数据库访问的缓存,相同的查询语句只需查询一次数据库,
二. oscache 主要是对页面的缓存,可以整页或者指定网页某一部分缓存,同时
指定他的过期时间,这样在此时间段里面访问的数据都是一样的
CentOS6.2环境配置
安装编译工具
yum
install wget make gcc gcc-c++ zlib-devel
openssl openssl-devel pcre-devel gd
kernel keyutils patch
perl
一、JDK6安装
1、安装JDK
把.bin文件COPY到待安装的指定目录下(可新建一个JAVA目录),执行如下命令后,JDK会安装在/usr/java下。
chmod
a+x jdk-6u32-linux-x64-rpm.bin
./jdk-6u32-linux-x64-rpm ...
你只需把页面的表格的html用jquery获取一下,然后传到后台,直接Response.Write(""),注意加上这句Response.ContentType = "application/vnd.ms-excel";另外有个问题,如果你样式写在外部的话,那导出来是没有样式的,是行内样式就能导出与html上一样的格式
package com.XXX.xheditor.servlet;
import java.io.BufferedOutputStream;
import java.io.File;
import java.io.FileOutputStream;
import java.io.IOException;
import java.io.OutputStream;
import java.io.PrintWriter;
import java.io.Serializable;
import java.text.SimpleD ...
方法一:
html源码:
<select name="select" onchange="changeSelectB()">
<option value="aaa">1</option>
<option value="bbb">2</option>
<option value="ccc">3</option>
<option value="ddd">4&l ...
使用FCKeditor编辑文章,有时候出于某种原因,提交失败了,需要返回修改。此时发现原来编辑好的文章中包含了一堆html代码!这个问题导致我,如果编辑的文章较长的时候,需要先复制一份到记事本备份,然后再提交。其实有一个简单的方法可以防止FCKeditor提交后返回自动添加html代码。
下面是解决方法:在FckEditor.Net
2.64和asp.net
2.0的环境下发现如下问题:如果浏览器执行返回动作,FckEditor编辑框内显示html代码解决方法是:修改文件FCKEditor\editor\fckeditor.html,在window.onload
=
fu ...
HttpClient client = new HttpClient();
GetMethod methodget = new GetMethod("xxxxx");
methodget.setFollowRedirects(true);
methodget.getParams().setParameter(HttpMethodParams.SINGLE_COOKIE_HEADER, true);
client.executeMethod(methodget);