eclipse + maven搭建SSM框架

时间:2023-01-15 12:23:31

0、系统环境

1)Windows 10 企业版

2)JDK 1.8.0_131

3)Eclipse Java EE IDE for Web Developers  Version: Neon.3 Release (4.6.3)

4)Tomcat 8.5

1、maven下载及配置

maven的下载地址:http://maven.apache.org/download.cgi

eclipse + maven搭建SSM框架

下载后解压放在d:\Java路径下

eclipse + maven搭建SSM框架

在环境变量中,新增系统变量名:MAVEN_HOME,变量值:D:\Java\maven

在Path中追加:%MAVEN_HOME%\bin;

在命令行窗口中输入:mvn –v,如果看见下图则说明maven安装配置完毕

eclipse + maven搭建SSM框架

2、maven仓库的设置

maven仓库默认位置在系统用户目录下的.m2目录中,类似下图

eclipse + maven搭建SSM框架

因为众所周知的原因,直接访问maven公共仓库的速度比较慢,所以推荐使用阿里的maven仓库镜像。编辑setting.xml文件,在mirrors节点下,新增如下内容,这样从仓库中下载jar包速度上会快很多。

<mirror>
<id>nexus-aliyun</id>
<mirrorOf>*</mirrorOf>
<name>Nexus aliyun</name>
<url>http://maven.aliyun.com/nexus/content/groups/public</url>
</mirror>

3、eclipse整合maven

设置eclipse自带maven整合工具,在Preferences中找到Maven节点,观察User Settings项的设置是否正确

eclipse + maven搭建SSM框架

点击Installations节点,添加maven runtime

eclipse + maven搭建SSM框架

4、创建maven项目时设置JDK

问题描述:eclipse创建maven项目时,显示的JDK默认版本为1.5,实际使用的JDK为1.8,如何修改?

解决方案:找到本机maven仓库存放位置,比如:${user.home}/.m2/路径,编辑settings.xml文件,在profiles节点下配置

eclipse + maven搭建SSM框架
<profile>

    <id>jdk-1.8</id>

    <activation>

        <activeByDefault>true</activeByDefault>

        <jdk>1.8</jdk>

    </activation>

    <properties>

        <maven.compiler.source>1.8</maven.compiler.source>

        <maven.compiler.target>1.8</maven.compiler.target>

        <maven.compiler.compilerVersion>1.8</maven.compiler.compilerVersion>

    </properties>

</profile>
eclipse + maven搭建SSM框架

5、使用maven创建SSM项目

1)选择Maven Project

eclipse + maven搭建SSM框架

2)点击Next,选择默认工作空间位置

eclipse + maven搭建SSM框架

3)选择web类型

eclipse + maven搭建SSM框架

4)填写GroupID、ArtifactID

eclipse + maven搭建SSM框架

Group ID:相当于一个组织

Artifact ID:相当于这个组织下的一个具体项目

Packege:根据Group ID和Artifact ID生成一个默认的名称

5)创建出的maven项目如下图

eclipse + maven搭建SSM框架

6)问题描述:提示错误:

eclipse + maven搭建SSM框架

在eclipse中设置Server为Tomcat,注意JRE设置为安装的JDK的jre

eclipse + maven搭建SSM框架

在工程上右键,查看工程属性,找到Java Build Path,添加Server Runtime为Tomcat

eclipse + maven搭建SSM框架

eclipse + maven搭建SSM框架

点击Finish后,项目工程变为下图

eclipse + maven搭建SSM框架

7)在项目上右键,查看项目信息

eclipse + maven搭建SSM框架

默认的Dynamic Web Module为2.3,使用Tomcat 8.5,需要修改为3.1

修改方法:

① maven工程所在目录下org.eclipse.wst.common.project.facet.core.xml

eclipse + maven搭建SSM框架

编辑内容,如下所示

eclipse + maven搭建SSM框架
<?xml version="1.0" encoding="UTF-8"?>

<faceted-project>

  <fixed facet="wst.jsdt.web"/>

  <installed facet="java" version="1.8"/>

  <installed facet="jst.web" version="2.3"/>

  <installed facet="wst.jsdt.web" version="1.0"/>

</faceted-project>
eclipse + maven搭建SSM框架

改为

eclipse + maven搭建SSM框架
<?xml version="1.0" encoding="UTF-8"?>

<faceted-project>

  <fixed facet="wst.jsdt.web"/>

  <installed facet="java" version="1.8"/>

  <installed facet="jst.web" version="3.1"/>

  <installed facet="wst.jsdt.web" version="1.0"/>

</faceted-project>
eclipse + maven搭建SSM框架

② maven工程下的web.xml文件修改为

<?xml version="1.0" encoding="UTF-8"?>
<web-app xmlns="http://xmlns.jcp.org/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/javaee http://xmlns.jcp.org/xml/ns/javaee/web-app_3_1.xsd"
version="3.1" metadata-complete="true">
</web-app>

③ pom.xml文件中修改build节点,添加如下内容

eclipse + maven搭建SSM框架
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>1.8</source>
<target>1.8</target>
</configuration>
</plugin>
</plugins>
eclipse + maven搭建SSM框架

④ 修改后,在项目上右键,找到Maven属性下的Update Project,点击之

eclipse + maven搭建SSM框架

⑤ 选择该项目进行更新,如果怕不能强制更新,可以勾选Force Update of Snapshots/Releases

eclipse + maven搭建SSM框架

⑥ 点击OK后更新maven项目,再观察项目属性,Module已经变为3.1

eclipse + maven搭建SSM框架

6、下载ssm框架所需jar包

修改pom.xml内容为:

eclipse + maven搭建SSM框架
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>cn.temptation</groupId>
<artifactId>ssm</artifactId>
<packaging>war</packaging>
<version>0.0.1-SNAPSHOT</version>
<name>ssm Maven Webapp</name>
<url>http://maven.apache.org</url>
<properties>
<!-- Spring版本号 -->
<spring.version>4.3.8.RELEASE</spring.version>
</properties>
<dependencies>
<!-- Spring相关包 -->
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-core</artifactId>
<version>${spring.version}</version>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-aop</artifactId>
<version>${spring.version}</version>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-web</artifactId>
<version>${spring.version}</version>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-webmvc</artifactId>
<version>${spring.version}</version>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-jdbc</artifactId>
<version>${spring.version}</version>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-tx</artifactId>
<version>${spring.version}</version>
</dependency> <!-- AOP相关包 -->
<dependency>
<groupId>org.aspectj</groupId>
<artifactId>aspectjrt</artifactId>
<version>1.8.0</version>
</dependency>
<dependency>
<groupId>org.aspectj</groupId>
<artifactId>aspectjweaver</artifactId>
<version>1.8.0</version>
</dependency> <!-- MyBatis相关包 -->
<dependency>
<groupId>org.mybatis</groupId>
<artifactId>mybatis</artifactId>
<version>3.3.0</version>
</dependency>
<!-- MySQL相关包 -->
<dependency>
<groupId>mysql</groupId>
<artifactId>mysql-connector-java</artifactId>
<version>5.1.26</version>
</dependency>
<!-- 数据库连接池 -->
<dependency>
<groupId>com.alibaba</groupId>
<artifactId>druid</artifactId>
<version>1.0.20</version>
</dependency> <!-- Spring集成MyBatis -->
<dependency>
<groupId>org.mybatis</groupId>
<artifactId>mybatis-spring</artifactId>
<version>1.2.3</version>
</dependency> <!-- JSP标准标签库 -->
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>jstl</artifactId>
<version>1.2</version>
</dependency> <!-- 日志相关包 -->
<dependency>
<groupId>log4j</groupId>
<artifactId>log4j</artifactId>
<version>1.2.17</version>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
<version>1.7.21</version>
</dependency> <!-- 单元测试相关包 -->
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>3.8.1</version>
<scope>test</scope>
</dependency>
</dependencies>
<build>
<finalName>ssm</finalName>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>1.8</source>
<target>1.8</target>
</configuration>
</plugin>
</plugins>
</build>
</project>
eclipse + maven搭建SSM框架

保存后,可以看到相关jar包被下载至本地仓库

7、完善项目结构

因为服务端maven项目的标准结构有四个子包:src/main/java、src/main/resources、src/test/java、src/test/resources,这里缺少了src/test/resources,所以手动补上。

在项目中新建Source Folder

eclipse + maven搭建SSM框架

创建src/test/resources目录后,工程如下图所示

eclipse + maven搭建SSM框架

右键查看项目属性,点击Deployment Assembly,移除test和target

eclipse + maven搭建SSM框架

移除后如下图

eclipse + maven搭建SSM框架

8、创建项目用的配置文件

eclipse + maven搭建SSM框架

创建log4j.properties文件,内容如下:

eclipse + maven搭建SSM框架
#USE THIS SETTING FOR OUTPUT MYBATIS`s SQL ON THE CONSOLE
log4j.rootLogger=DEBUG, Console #Console
log4j.appender.Console=org.apache.log4j.ConsoleAppender
log4j.appender.Console.layout=org.apache.log4j.PatternLayout
log4j.appender.Console.layout.ConversionPattern=%d [%t] %-5p [%c] - %m%n log4j.logger.java.sql.ResultSet=INFO
log4j.logger.org.apache=INFO
log4j.logger.java.sql.Connection=DEBUG
log4j.logger.java.sql.Statement=DEBUG
log4j.logger.java.sql.PreparedStatement=DEBUG
eclipse + maven搭建SSM框架

创建mybatis-config.xml文件,内容如下:

eclipse + maven搭建SSM框架
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE configuration
PUBLIC "-//mybatis.org//DTD Config 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-config.dtd">
<configuration>
<!-- 设置别名 -->
<typeAliases>
<package name="cn.temptation.domain" />
</typeAliases>
</configuration>
eclipse + maven搭建SSM框架

创建spring-mvc.xml文件,内容如下:

eclipse + maven搭建SSM框架
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:context="http://www.springframework.org/schema/context"
xmlns:mvc="http://www.springframework.org/schema/mvc"
xsi:schemaLocation="
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context.xsd
http://www.springframework.org/schema/mvc http://www.springframework.org/schema/mvc/spring-mvc.xsd"> <!-- 启动自动扫描 -->
<context:component-scan base-package="cn.temptation.*" /> <!-- 注册MVC注解驱动 -->
<mvc:annotation-driven /> <!-- 静态资源可访问的设置方式 -->
<mvc:default-servlet-handler /> <!-- 配置视图解析器,可以显式设置,也可以不设置,不设置会依据SpringMVC的默认设置 -->
<bean id="viewResolver"
class="org.springframework.web.servlet.view.InternalResourceViewResolver">
<property name="prefix" value="/" />
<property name="suffix" value=".jsp" />
</bean>
</beans>
eclipse + maven搭建SSM框架

创建spring-mybatis.xml文件,内容如下:

eclipse + maven搭建SSM框架
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd"> <!-- 定义数据源Bean -->
<!-- Druid -->
<bean id="dataSource" class="com.alibaba.druid.pool.DruidDataSource">
<property name="url" value="jdbc:mysql://localhost:3306/test" />
<property name="username" value="root" />
<property name="password" value="sa" />
</bean> <!-- 注册SqlSessionFactoryBean -->
<bean id="sqlSessionFactory" class="org.mybatis.spring.SqlSessionFactoryBean">
<property name="dataSource" ref="dataSource" />
<!-- 自动扫描mappers.xml文件 -->
<property name="mapperLocations" value="classpath:cn/temptation/dao/*.xml" />
<property name="configLocation" value="classpath:mybatis-config.xml"></property>
</bean> <!-- DAO接口所在包名,Spring会自动查找其下的类 -->
<bean class="org.mybatis.spring.mapper.MapperScannerConfigurer">
<property name="basePackage" value="cn.temptation.dao" />
<property name="sqlSessionFactoryBeanName" value="sqlSessionFactory" />
</bean>
</beans>
eclipse + maven搭建SSM框架

创建spring-tx.xml文件,内容如下:

eclipse + maven搭建SSM框架
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:context="http://www.springframework.org/schema/context"
xmlns:aop="http://www.springframework.org/schema/aop"
xmlns:tx="http://www.springframework.org/schema/tx"
xsi:schemaLocation="
http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context.xsd
http://www.springframework.org/schema/aop http://www.springframework.org/schema/aop/spring-aop.xsd
http://www.springframework.org/schema/tx http://www.springframework.org/schema/tx/spring-tx.xsd"> <!-- 开启AOP注解扫描 -->
<aop:aspectj-autoproxy proxy-target-class="true" /> <!-- 事务管理器,依赖于数据源 -->
<bean id="txManager" class="org.springframework.jdbc.datasource.DataSourceTransactionManager">
<property name="dataSource" ref="dataSource" />
</bean> <!-- 编写通知:对事务进行增强(通知),需要编写对切入点和具体执行事务细节 -->
<tx:advice id="txAdvice" transaction-manager="txManager">
<tx:attributes>
<!--
为切入点方法添加事务详情
name:方法名,*表示任意方法名称
propagation:设置传播行为
isolation:设置隔离级别
read-only:是否只读
-->
<tx:method name="add*" propagation="REQUIRED" isolation="DEFAULT" read-only="false" rollback-for="Exception" />
<tx:method name="delete*" propagation="REQUIRED" isolation="DEFAULT" read-only="false" rollback-for="Exception" />
<tx:method name="update*" propagation="REQUIRED" isolation="DEFAULT" read-only="false" rollback-for="Exception" />
</tx:attributes>
</tx:advice> <!-- 设置AOP,让Spring自动对目标生成代理,需要使用AspectJ表达式 -->
<aop:config proxy-target-class="true">
<!-- 切面:整合切入点和通知 -->
<aop:advisor advice-ref="txAdvice" pointcut="within(cn.temptation.web..*)" />
</aop:config>
</beans>
eclipse + maven搭建SSM框架

9、编写服务端代码

eclipse + maven搭建SSM框架

编写User实体类,代码如下:

eclipse + maven搭建SSM框架
package cn.temptation.domain;

/**
* 用户信息
*/
public class User {
// 成员变量
private Integer userid;
private String username;
private String password; // 构造函数
public User() {
super();
} public User(Integer userid, String username, String password) {
super();
this.userid = userid;
this.username = username;
this.password = password;
} // 成员方法
public Integer getUserid() {
return userid;
} public void setUserid(Integer userid) {
this.userid = userid;
} public String getUsername() {
return username;
} public void setUsername(String username) {
this.username = username;
} public String getPassword() {
return password;
} public void setPassword(String password) {
this.password = password;
}
}
eclipse + maven搭建SSM框架

编写UserController控制器,代码如下:

eclipse + maven搭建SSM框架
package cn.temptation.web;

import javax.annotation.Resource;
import javax.servlet.http.HttpSession; import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.servlet.ModelAndView; import cn.temptation.dao.UserDao;
import cn.temptation.domain.User; /**
* 用户控制器
*/
@Controller
@RequestMapping(value = "/user")
public class UserController {
@Resource
private UserDao userDao; @RequestMapping("/view")
public String view() {
return "main/login";
} @RequestMapping("/indexview")
public String index() {
return "main/index";
} @RequestMapping(value = "/login", method = RequestMethod.POST)
public ModelAndView login(User model, HttpSession session) {
User user = userDao.findByUsername(model.getUsername()); if (user == null || !user.getPassword().equals(model.getPassword())) {
return new ModelAndView("redirect:/login.jsp");
} else {
session.setAttribute("user", user);
ModelAndView mav = new ModelAndView();
mav.setViewName("index");
return mav;
}
}
}
eclipse + maven搭建SSM框架

编写UserDao数据访问层接口,代码如下:

eclipse + maven搭建SSM框架
package cn.temptation.dao;

import cn.temptation.domain.User;

public interface UserDao {
public abstract User findByUsername(String username);
}
eclipse + maven搭建SSM框架

编写UserMapper.xml数据访问层映射文件,代码如下:

eclipse + maven搭建SSM框架
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="cn.temptation.dao.UserDao">
<select id="findByUsername" parameterType="string" resultType="User">
SELECT * FROM userinfo WHERE username=#{username}
</select>
</mapper>
eclipse + maven搭建SSM框架

10、编写客户端代码

eclipse + maven搭建SSM框架

编写login.jsp登录页,代码如下:

eclipse + maven搭建SSM框架
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>登录</title>
</head>
<body>
<form action="user/login" method="post">
<label>账号:</label>
<input type="text" id="txtUsername" name="username" placeholder="请输入账号" /><br/>
<label>密码:</label>
<input type="password" id="txtPassword" name="password" placeholder="请输入密码" /><br/>
<input type="submit" value="提交" />
<input type="reset" value="重置" />
</form>
</body>
</html>
eclipse + maven搭建SSM框架

编写index.jsp主页,代码如下:

eclipse + maven搭建SSM框架
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>主页</title>
</head>
<body>
<h3>欢迎,${user.username }</h3>
</body>
</html>
eclipse + maven搭建SSM框架

11、使用maven构建项目

在项目上右键,找到Maven属性的Update Project,也可以Alt+F5操作

eclipse + maven搭建SSM框架

修改项目编译路径为JRE系统类库,否则后续操作出错

eclipse + maven搭建SSM框架

项目上右键,找到Run As属性,找到Maven install

eclipse + maven搭建SSM框架

点击执行,结果如下说明构建成功

eclipse + maven搭建SSM框架

项目运行还是使用web工程的部署运行方式

eclipse + maven搭建SSM框架

运行项目,观察是否报错

eclipse + maven搭建SSM框架

登录页面

eclipse + maven搭建SSM框架

登录成功,跳转到主页

eclipse + maven搭建SSM框架

eclipse + maven搭建SSM框架的更多相关文章

  1. 【原】无脑操作:eclipse &plus; maven搭建SSM框架

    网上看到一些Spring + Spring MVC + MyBatis框架的搭建教程,不是很详细或是时间久远了,自己动手整一个简单无脑的! 0.系统环境 1)Windows 10 企业版 2)JDK ...

  2. Eclipse中使用Maven搭建SSM框架

    Eclipse中不使用Maven搭建SSM框架:https://www.cnblogs.com/xuyiqing/p/9569459.html IDEA中使用Maven搭建SSM框架:https:// ...

  3. 使用Maven搭建SSM框架(Eclipse)

    今天学习一下使用Maven搭建SSM框架,以前都是用别人配置好的框架写代码,今天试试自己配置一下SSM框架. 这里我的参数是Windows7 64位,tomcat9,eclipse-jee-neon- ...

  4. 使用maven搭建ssm框架的javaweb项目

    目前主流的javaweb项目,常会用到ssm(Spring+Spring MVC+Mybatis)框架来搭建项目的主体框架,本篇介绍搭建SSM框架的maven项目的实施流程.记之共享! 一.SSM框架 ...

  5. 使用maven搭建SSM框架

    使用maven搭建SSM框架,首先得准备好maven环境. 搭建maven环境 第一步:下载maven http://maven.apache.org/download.cgi 下载后解压就可以了. ...

  6. Maven项目搭建(二):Maven搭建SSM框架

    上一章给大家讲解了如何使用Maven搭建web项目. 这次给大家介绍一下怎么使用Maven搭建SSM框架项目. 首先我们来看一下pom.xml的属性介绍: project: pom的xml根元素. p ...

  7. 使用maven搭建ssm框架环境

    1.前言 因为经常换环境,在搭ssm框架的时候老是出错,所以记录一下最近搭建的环境,以供参考. 本文讲解如何使用maven搭建ssm框架,并能用于简单的登录注册. IDE:IDEA,JDK版本:1.8 ...

  8. Maven 搭建 SSM框架——Spring&plus;SpringMVC&plus;Mybatis的搭建教程

    一:概述 SSM框架在项目开发中经常使用到,相比于SSH框架,它在仅几年的开发中运用的更加广泛. Spring作为一个轻量级的框架,有很多的拓展功能,最主要的我们一般项目使用的就是IOC和AOP.Sp ...

  9. IDEA使用 maven 搭建 SSM 框架

    文章目录 pom 文件的编写 项目结构 SSM 配置文件的编写 web.xml 的配置 总结 公司有个小的内部使用的软件,让开发,自己选择使用 SSM :因为之前自己学过,本以为一切水到渠成,但是好久 ...

随机推荐

  1. 【转载】WEB前端开发规范文档

    本文转载自谈笑涧<WEB前端开发规范文档> 为 新项目写的一份规范文档, 分享给大家. 我想前端开发过程中, 无论是团队开发, 还是单兵做站, 有一份开发文档做规范, 对开发工作都是很有益 ...

  2. ssh localhost无密码登录设置

    亲测... ssh-keygen -t dsa -P '' -f ~/.ssh/id_dsa cat ~/.ssh/id_dsa.pub >> ~/.ssh/authorized_keys ...

  3. 注册表检测office版本

    #region 查询注册表,判断本机是否安装Office2003,2007和WPS public int ExistsRegedit() { int ifused = 0; RegistryKey r ...

  4. js缓存问题的解决

  5. SQL分区表示例

    -- Create tablecreate table TT_FVP_OCR_ADDRESS( id NUMBER not null, waybill_no VARCHAR2(32) not null ...

  6. &lpar;2&rpar;R中的数据类型和数据结构

    R中的数据结构主要面向<线性代数>中的一些概念,如向量.矩阵等.值得注意的是,R中其实没有简单数据(数值型.逻辑型.字符型等),对于简单类型会自动看做长度为1的向量.比如: > b= ...

  7. Linux安装ftp组件vsftpd

    1 安装vsftpd组件 安装完后,有/etc/vsftpd/vsftpd.conf 文件,是vsftp的配置文件. [root@bogon ~]# yum -y install vsftpd 2 添 ...

  8. Knockoutjs&plus;select2 人员搜索

    HTML: <select class="form-control PersonEmail" id="txtProjectManager" data-bi ...

  9. 6、C&plus;&plus;共用体

    6.共用体 共用体(union)是一种数据格式,他能够存储不同的数据类型,但只能同时存储其中的一种类型.也就是说,结构可以同时存储int.long和double,共用体只能存储ing.long.dou ...

  10. jQuery的一些备忘

    操作元素的样式 主要包括以下几种方式: $("#msg").css("background"); //返回元素的背景颜色 $("#msg") ...