`

dual is not mapped,select ordercode_seq_id.nextval nextvalue from dual

阅读更多

          项目中,用到一个序列作单号,框架用的是ssh,在dao层去拿的时候,运行时报错为dual is not mapped,[select ordercode_seq_id.nextval nextvalue from dual]

           后来检查发现,获取方式不对,于是改成下面这样,就可以正常获取了

	public String getOrderCode() {
		try {
			String sql = "select ordercode_seq_id.nextval nextvalue from dual";
			Integer maxId = (Integer)(this.getSession().createSQLQuery(sql).addScalar("nextvalue", Hibernate.INTEGER) ).uniqueResult();
			return maxId.toString();
		} catch (Exception e) {
			e.printStackTrace();
		}
		return null;
	}

 

0
2
分享到:
评论

相关推荐

    ACM经典代码_相当不错的资料.pdf

    5. 最小生成树(prim+mapped_heap 邻接表形式) .. 21 6. 最小生成树(prim+mapped_heap 正向表形式) .. 22 7. 最小生成树(prim 邻接阵形式)... 23 8. 最小树形图(邻接阵形式) . 24 四.图论_网络流 ... 25 1. 上下界...

    DSP280x_Headers_nonBIOS.cmd

    This file is for use in Non-BIOS applications. Linker command file to place the peripheral structures used within the DSP280x headerfiles into the correct memory mapped locations. This version of ...

    Vega_STDP4028_DS.pdf

    The STDP4028 is a DisplayPort transmitter IC for the secure transmission of high-bandwidth, uncompressed digital audio-video signals targeted for applications such as DTV, LCD monitor, docking station...

    Delphi 修改内存保护属性.rar

    Delphi 修改内存保护属性,包括修改以下信息:基地址、分配地址、区域大孝所分配... MEM_MAPPED: ListBox1.Items.Add('内存类型: MEM_MAPPED');  MEM_PRIVATE: ListBox1.Items.Add('内存类型: MEM_PRIVATE');  end;

    IBatisNet_mytest001_20191031_内含反编译源码.rar

    更新类IBatisNet.DataMapper.MappedStatements.ResultStrategy.DictionaryStrategy,处理数据输出类型是HashTable, 不能解析特定数据库专有数据类型的错误

    fifo_32in256out.rar_AXI_AXI FIFO_axi fifo_axi-dma_fifo32

    he AXI Streaming FIFO allows memory mapped access to a AXI Streaming interface. The core can be used to interface to the AXI Ethernet without the need to use DMA.

    free_and_open_source_software_for_development.pdf

    has not been well mapped. This book is about FOSS for Development (FOSS4D). We will focus on the Least Developed Countries (LDC's) and primarily on the African context. Most of the LDC's are in Africa...

    Advanced Linux 3D graphics programming

    Light Mapped Polygons ...................................142 Software Rasterization of Light Maps............................147 Hardware Light Mapping....................................147 Sample ...

    原创GSM基带信号的中频调制-qam_symbol_mapped.m

    原创GSM基带信号的中频调制-qam_symbol_mapped.m 这是GSM基带信号的处理程序,包括符号映射、插值、调制等过程

    JLink_Windows_V648.zip

    Firmware: Flasher ARM / PRO / Portable PLUS: Stand-alone mode did not work for some devices from Analog Devices (e.g. ADuCM7023). Fixed. Firmware: Flasher ARM / PRO: FWrite command was unable to ...

    SSD7 选择题。Multiple-Choice

    When mapping from an ER model to a relational model, a strong entity is mapped into a (a) table (b) row (c) column (d) key Correct answer is (a) 10. Which of the following is true about ...

    flex:使用多个序列比对工具的共识序列管道

    python3 find_mapped_reads.py [fasta file with reads] [m5 mapping output from blasr] [start index] [end index] [output file name]示例: python3 find_mapped_reads.py reads.fa mapping.m5 100 5100 reads_...

    循环分析脚本

    循环分析脚本 ... bedtools window -a anyLoops_AML_1.bed -b hg38.gff -w 15000 > mapped_anyLoops_AML_1.csv bedtools window -a anyLoops_AML_2.bed -b hg38.gff -w 15000 > mapped_anyLoops_AML_2.csv bed

    ACM经典算法及例子

    5. 最小生成树(prim+mapped_heap邻接表形式) 21 6. 最小生成树(prim+mapped_heap正向表形式) 22 7. 最小生成树(prim邻接阵形式) 23 8. 最小树形图(邻接阵形式) 24 四.图论_网络流 25 1. 上下界最大流(邻接表形式) ...

    ACM常用算法代码 pdf

    5. 最小生成树(prim+mapped_heap邻接表形式) 21 6. 最小生成树(prim+mapped_heap正向表形式) 22 7. 最小生成树(prim邻接阵形式) 23 8. 最小树形图(邻接阵形式) 24 四.图论_网络流 25 1. 上下界最大流(邻接表形式) ...

    mybatisMapped报错 Statements collection does not contain value for

    mytabis 报错 Mapped Statements collection does not contain value for

    非常经典的acm程序代码

    5. 最小生成树(prim+mapped_heap邻接表形式) 21 6. 最小生成树(prim+mapped_heap正向表形式) 22 7. 最小生成树(prim邻接阵形式) 23 8. 最小树形图(邻接阵形式) 24 四.图论_网络流 25 1. 上下界最大流(邻接表...

    MappedFile_source.zip_内存

    存贮内存数据到文件里

    scsi_tgt_priv.rar_V2

    Basic memory-mapped GPIO controllers for Linux v2.13.6.

    fsl_85xx_cache_ctlr.rar_cache memory_memory

    QorIQ based Cache Controller Memory Mapped Registers.

Global site tag (gtag.js) - Google Analytics