• Sequences

2013-10-20 16:41:16
Sequences

Sequences

A sequence is a schema object from which multiple users can generate unique integers. A sequence generator provides a highly scalable and well-performing method to generate surrogate keys for a number data type.

Sequence Characteristics

A sequence definition indicates general information, such as the following:
■The name of the sequence
■Whether the sequence ascends or descends
■The interval between numbers
■Whether the database should cache sets of generated sequence numbers in memory
■Whether the sequence should cycle when a limit is reached

The following example creates the sequence customers_seq in the sample schema oe. An application could use this sequence to provide customer ID numbers when rows are added to the customers table.

CREATE SEQUENCE customers_seq
INCREMENT BY 1
NOCACHE
NOCYCLE;

The first reference to customers_seq.nextval returns 1000. The second returns 1001. Each subsequent reference returns a value 1 greater than the previous reference.

The same sequence generator can generate numbers for multiple tables. In this way, the database can generate primary keys automatically and coordinate keys across multiple rows or tables. For example, a sequence can generate primary keys for an orders table and a customers table.
The sequence generator is useful in multiuser environments for generating unique numbers without the overhead of disk I/O or transaction locking. For example, two users simultaneously insert new rows into the orders table. By using a sequence to generate unique numbers for the order_id column, neither user has to wait for the other to enter the next available order number. The sequence automatically generates the correct values for each user.
Each user that references a sequence has access to his or her current sequence number, which is the last sequence generated in the session. A user can issue a statement to generate a new sequence number or use the current number last generated by the session. After a statement in a session generates a sequence number, it is available only to this session. Individual sequence numbers can be skipped if they were generated and used in a transaction that was ultimately rolled back.

Caution:
If your application requires a gap-free set of numbers, then you cannot use Oracle sequences. You must serialize activities in the database using your own developed code.

展开全文
• sequences

2019-10-05 19:20:23
1 内存库（SMDB）修改sequences OCS割接一般涉及的内存库sequences 日志相关表： OCS_RECHARGELOG_I.RECINDEX OCS_RECHARGELOG_I OCS_ACCTMGRLOG_I.RECINDEX OCS_ACCTMGRLOG_I 欠费相关表： OCS_CYCLEUNPAID...

1      内存库（SMDB）修改sequences

OCS割接一般涉及的内存库sequences

日志相关表：

OCS_RECHARGELOG_I.RECINDEX        OCS_RECHARGELOG_I

OCS_ACCTMGRLOG_I.RECINDEX         OCS_ACCTMGRLOG_I

欠费相关表：

OCS_CYCLEUNPAID_I. RECINDEX         OCS_CYCLEUNPAID_I

分期回赠表键值相关表：

REBATE.REBATEKEY                     SEQUENCE_REBATE

1.1      查询sequences

在mdsql下执行一下命令查询各个sequence信息：

1.3      修改sequences

如果想修改sequence，需要先删除，再重建一下；

drop SEQUENCE OCS_ACCTMGRLOG_I;

create sequence ocs_acctmgrlog_i increment 1 minvalue 1000000 maxvalue 9223372036854775807;

标红的1000000为需要修改的序列号开始值，请根据实际需要修改该值；

1.4      恢复sequences

只有需要回滚恢复sequence时才操作此步骤！

恢复也需要采用先删除再重建方式；

drop SEQUENCE OCS_ACCTMGRLOG_I;

create sequence ocs_acctmgrlog_i increment 1 minvalue 1 maxvalue 9223372036854775807;

drop SEQUENCE SEQ_Dxfrequire ;

increment by 1 nocache ;

注：标红的1为修改之前的值，可以通过备份文件seq.unl得到；

转载于:https://www.cnblogs.com/JPAORM/archive/2011/09/15/2510318.html

展开全文
• Natural protein sequences are more intrinsically disordered than random sequences
• Distribution properties of binary sequences derived from primitive sequences modulo square-free odd integers
• training sequences

2021-03-17 11:20:02
training sequences由order sets组成，用来实现bit对齐、symbol对齐和交换物理层参数.

training sequences由order sets组成，用来实现bit对齐、symbol对齐和交换物理层参数.当速率是2.5G或者5G时，数据不会被加扰，但是会尽心8b/10b编码；8G速率及以上时，会做128b/130b编码，可以加扰也可以不加扰.

展开全文
• CG.Sequences.CosmoDb： 它有什么作用？ 该软件包包含CG.Sequences软件包的CosmoDb扩展。 常用类型： CG.Sequences.CosmoDb.Repositories.CosmoDbSequenceRepository CG.Sequences.CosmoDb.Repositories.Options....
• <SPAN lang=EN-US xss=removed>Maximal length FCSR sequences, or <I>l</I>-sequences, are an important type of nonlinear sequences used for building stream ciphers. This paper studies the linearity ...
• Further Results on the Distinctness of Binary Sequences Derived From Primitive Sequences Modulo Square-Free Odd Integers
• If there are several such sequences, pick the one which has the largest first value;if there's a tie, the largest second number, etc. Sample Input 3456 3546 3526 0001 100000101 0 Sample Output 3,4...
• This letter investigates the construction methods of perfect 8-QAM+ sequences, which relate to one of three open problems proposed by Boztas and Parampalli in 2010, and two constructions that ...
• Configuring Sequences with SFCpdf,Configuring Sequences with SFC
• Sample Identification Sequences
• <p><img alt="tofu in wincompose sequences dialog" src="https://img-blog.csdnimg.cn/img_convert/71584cf40db25889e5c3259db7702bdf.png" /></p><p>该提问来源于开源项目：samhocevar/wincompose</p></div...
• <SPAN lang=EN-US xss=removed>In this paper, the autocorrelation of maximal period Feedback with Carry Shift Register sequences (<I xss=removed>l</I>-sequences) are discussed. For an <I xss=removed>
• To avoid enumerating the possible combinations, it is sometimes easier to talk about sequences of sequences. In many contexts, the different kinds of sequences (strings, lists and tuples) can be used...

I have focused on lists of tuples, but almost all the examples in this chapter also work with lists of lists, tuples of tuples, and tuples of lists. To avoid enumerating the possible combinations, it is sometimes easier to talk about sequences of sequences. In many contexts, the different kinds of sequences (strings, lists and tuples) can be used interchangeably. So how and why do you choose one over the others.

To start with the obvious, strings are more limited than other sequences because the elements have to be characters. They are also immutable. If you need the ability to change the characters in a string (as opposed to creating a new string), you might want to use a list of characters instead.

Lists are more common than tuples, mostly because they are mutable. But there are a few cases where you might prefer tuples:

• In some contexts, like a return statement, it is syntactically simpler to create a tuple than a list.
• If you want to use a sequence as a dictionary key, you have to use an immutable type like a tuple or string.
• If you passing a sequence as an argument to a function, using tuples reduces the potential for unexpected behavior due to aliasing.

Because tuples are immutable, they don’t provide methods like sort and reverse, which modify existing lists. But Python provides the built-in functions sorted and reversed, which take any sequence as a parameter and return a new list with the same elements in a different order.

from Thinking in Python

转载于:https://www.cnblogs.com/ryansunyu/p/3866439.html

展开全文
• Sequences用法

2007-12-20 21:41:02
Sequences用法 主要介绍oracle 如何设置自增
• Frequent patterns mining in multiple biological sequences
• Understanding Social Causalities Behind Human Action Sequences
• a new generalized cyclotomy with respect to a positive odd integer is introduced, and a construction of frequency hopping sequence sets and two constructions of frequency hopping sequences are ...
• Two Shuffled Sequences time limit per test2 seconds memory limit per test256 megabytes inputstandard input outputstandard output Two integer sequences existed initially — one of them was strictly i....
• Stopping - all 545 input sequences aligned poorly to reference sequences (--min_align option specified a minimum proportion of 0.8 aligning to reference sequences). 需要对otu.fa取反向 再进行分析 ...
• Jzzhu and Sequences Jzzhu has invented a kind of sequences, they meet the following property: f1=x,f2=y;对任意i>=2，fi=f（i-1）+f(i-2); You are given x and y, please calculate fn modulo 1000000007 ...
• data structures for text sequences.zip
• On the generalized large set of Kasami sequences
• Discriminative Dimensionality Reduction for Multi-Dimensional Sequences
• Find the Sequences

2017-08-24 11:08:42
Your task is to find out all such sequences whose elements are of the form p3+q3 where p and q are non-negative integers. Input: The input consists of multiple test cases. In each case, there're ...

...