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

Hibernate,java,sqlÀàÐ͵ĶÔÓ¦¹Øϵ


JavaÊý¾ÝÀàÐÍ
HibernateÊý¾ÝÀàÐÍ
±ê×¼SQLÊý¾ÝÀàÐÍ
byte
byte
TINYINT
short
short
SMALLINT
int
integer
INGEGER
long
long
BIGINT
float
float
FLOAT
double
double
DOUBLE
java.math.BigDecimal
big_decimal
NUMERIC
char, java.lang.Character
character
CHAR(1)
boolean, java.lang.Boolean
Boolean/yes_no/true_false
BIT/ CHAR(1)('Y'»ò'N')
java.lang.String
string
VARCHAR
java.util.Date, java.sql.Date
Date/time
DATE/TIME
java.util.Date, java.sql.Timestamp
timestamp
TIMESTAMP
java.util.Calendar
calendar
TIMESTAMP
java.util.Calendar
calendar_date
DATE
byte[]
binary
VARBINARY, BLOB
java.lang.String
text
CLOB
java.io.Serializable
serializable
VARBINARY, BLOB
java.sql.Clob
clob
CLOB
java.sql.Blob
blob
BLOB
java.lang.Class
class
VARCHAR
java.util.Locale
locale
VARCHAR
java.util.TimeZone
timezone
VARCHAR
java.util.Currency
currency
VARCHAR
Õâ¸ö²»ÊǺÜÈ·¶¨£¬ÍøÉϳ­µÄ£¬Óз¢ÏÖ´íÎóÔÙ¸üÕý°É¡£


Ïà¹ØÎĵµ£º

sql 2005 ´æ´¢¹ý³Ì·ÖÒ³ java ´úÂë

 create PROCEDURE pagelist
@tablename nvarchar(50),
@fieldname nvarchar(50)='*',         
@pagesize int output,--ÿҳÏÔʾ¼Ç¼ÌõÊý
@currentpage int output,--µÚ¼¸Ò³
@orderid nvarchar(50),--Ö÷¼üÅÅÐò
@sort int,--ÅÅÐò·½Ê½£¬1±íʾÉýÐò£¬0±íʾ½µÐòÅÅÁÐ ......

JSTL(SQL)

SQL
<%@ taglib uri="http://java.sun.com/jsp/jstl/sql" prefix="sql" %>
1.<sql:setDataSource>
ÉèÖÃÊý¾ÝÔ´
<sql:setDataSource dataSource=""|url="jdbcUrl" driver="" user="" password=""
 var="varName" scope=""/>
var:String DataSource
dataSourceµÄÖµÓÐÁ½ÖÖÐÎʽ£º1.Ö¸¶¨Êý¾ÝÔ´µÄJ ......

SQL´´½¨Êý¾Ý¿â¡¢±í¡¢´æ´¢¹ý³Ì¼°µ÷ÓÃ

--Èç¹û´æÔÚÊý¾Ý¿âprogrammerPay  ¾Íɾ³ý
if exists (select * from sysdatabases where name='programmerPay')
drop database programmerPay
go
--´´½¨Êý¾Ý¿âprogrammerPay
create database programmerPay
on primary
(
name ='programmerPay_data',
filename='D:\programmerPay\programmerPay_data.mdf',
......

SQL 92 ±ê×¼ YoYo

        ÏîÄ¿ÖÕÓÚ½áÊøÁË£¬×ܽáµÄʱºòµ½ÁË... hehe :)
        ÔÚÏîÄ¿ÖÐÎÒÃÇÓöµ½Á˺ܶàµÄÎÊÌ⣬±ê×¼SQLʹÓþÍÊÇÆäÖÐÒ»¸ö¡£ ÒòΪÎÒÃÇÔÚ×öBI packageµÄʱºò£¬Ò»¿ªÊ¼¶¼ÊÇ»ùÓÚMS SQL À´×öµÄ£¬ËùÒÔUniverseµÄÉè¼ÆÉÏҲûÓÐÌ«¶àµÄ¿¼ÂÇ¡£ µ±ºóÀ´ÀÏ´ó¸æËßÎÒÅ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ