如何在 SQLite 中创建序列? [英] How can I create a sequence in SQLite?
本文介绍了如何在 SQLite 中创建序列?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我在 sqlite 中创建了一个表.有两个字段:pk_categoryid
、category_name
.我只想从用户端输入一个值.那么,如何创建序列?
I have created a table in sqlite.
There are two fields: pk_categoryid
,category_name
.
I want to enter only one value from the user side.
So, how can I create a sequence?
推荐答案
如果您的意思是希望自动生成主键,那么在创建表时查看AUTOINCREMENT
:
If you mean that you want the primary key to be autogenerated, then look at AUTOINCREMENT
when creating your table:
这篇关于如何在 SQLite 中创建序列?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文