真实的国产乱ⅩXXX66竹夫人,五月香六月婷婷激情综合,亚洲日本VA一区二区三区,亚洲精品一区二区三区麻豆

成都創(chuàng)新互聯(lián)網(wǎng)站制作重慶分公司

PostgreSQL的OID類型是什么-創(chuàng)新互聯(lián)

這篇文章主要介紹“PostgreSQL的OID類型是什么”,在日常操作中,相信很多人在PostgreSQL的OID類型是什么問題上存在疑惑,小編查閱了各式資料,整理出簡(jiǎn)單好用的操作方法,希望對(duì)大家解答”PostgreSQL的OID類型是什么”的疑惑有所幫助!接下來,請(qǐng)跟著小編一起來學(xué)習(xí)吧!

為佛山等地區(qū)用戶提供了全套網(wǎng)頁設(shè)計(jì)制作服務(wù),及佛山網(wǎng)站建設(shè)行業(yè)解決方案。主營業(yè)務(wù)為成都做網(wǎng)站、成都網(wǎng)站設(shè)計(jì)、成都外貿(mào)網(wǎng)站建設(shè)、佛山網(wǎng)站設(shè)計(jì),以傳統(tǒng)方式定制建設(shè)網(wǎng)站,并提供域名空間備案等一條龍服務(wù),秉承以專業(yè)、用心的態(tài)度為用戶提供真誠的服務(wù)。我們深信只要達(dá)到每一位用戶的要求,就會(huì)得到認(rèn)可,從而選擇與我們長期合作。這樣,我們也可以走得更遠(yuǎn)!

OID定義為無符號(hào)整型數(shù)字,PG內(nèi)置了轉(zhuǎn)換函數(shù)從regproc, regprocedure, regoper, regoperator, regclass, regtype, regrole, regnamespace, regconfig, and regdictionary這些類型轉(zhuǎn)換為OID.

TODO

下面是一些例子:
查詢某張表的屬性

[local]:5432 pg12@testdb=# SELECT * FROM pg_attribute
  WHERE attrelid = (SELECT oid FROM pg_class WHERE relname = 'tbl') limit 1;
-[ RECORD 1 ]-+---------
attrelid      | 32774
attname       | tableoid
atttypid      | 26
attstattarget | 0
attlen        | 4
attnum        | -6
attndims      | 0
attcacheoff   | -1
atttypmod     | -1
attbyval      | t
attstorage    | p
attalign      | i
attnotnull    | t
atthasdef     | f
atthasmissing | f
attidentity   | 
attgenerated  | 
attisdropped  | f
attislocal    | t
attinhcount   | 0
attcollation  | 0
attacl        | 
attoptions    | 
attfdwoptions | 
attmissingval | 
Time: 5.209 ms
-->
[local]:5432 pg12@testdb=# SELECT * FROM pg_attribute where attrelid = 'tbl'::regclass limit 1;
-[ RECORD 1 ]-+---------
attrelid      | 32774
attname       | tableoid
atttypid      | 26
attstattarget | 0
attlen        | 4
attnum        | -6
attndims      | 0
attcacheoff   | -1
atttypmod     | -1
attbyval      | t
attstorage    | p
attalign      | i
attnotnull    | t
atthasdef     | f
atthasmissing | f
attidentity   | 
attgenerated  | 
attisdropped  | f
attislocal    | t
attinhcount   | 0
attcollation  | 0
attacl        | 
attoptions    | 
attfdwoptions | 
attmissingval | 
Time: 1.205 ms

查詢操作符+的相關(guān)信息

[local]:5432 pg12@testdb=# select * from pg_operator where oid='+(int,float)'::regoperator;
ERROR:  operator does not exist: +(int,float)
LINE 1: select * from pg_operator where oid='+(int,float)'::regopera...
                                            ^
Time: 1.502 ms
[local]:5432 pg12@testdb=# select * from pg_operator where oid='+(float,float)'::regoperator;
-[ RECORD 1 ]+---------
oid          | 591
oprname      | +
oprnamespace | 11
oprowner     | 10
oprkind      | b
oprcanmerge  | f
oprcanhash   | f
oprleft      | 701
oprright     | 701
oprresult    | 701
oprcom       | 591
oprnegate    | 0
oprcode      | float8pl
oprrest      | -
oprjoin      | -
Time: 3.446 ms

注意:操作符需指定參數(shù).

到此,關(guān)于“PostgreSQL的OID類型是什么”的學(xué)習(xí)就結(jié)束了,希望能夠解決大家的疑惑。理論與實(shí)踐的搭配能更好的幫助大家學(xué)習(xí),快去試試吧!若想繼續(xù)學(xué)習(xí)更多相關(guān)知識(shí),請(qǐng)繼續(xù)關(guān)注創(chuàng)新互聯(lián)-成都網(wǎng)站建設(shè)公司網(wǎng)站,小編會(huì)繼續(xù)努力為大家?guī)砀鄬?shí)用的文章!


網(wǎng)頁名稱:PostgreSQL的OID類型是什么-創(chuàng)新互聯(lián)
本文路徑:http://weahome.cn/article/ppsos.html

其他資訊

在線咨詢

微信咨詢

電話咨詢

028-86922220(工作日)

18980820575(7×24)

提交需求

返回頂部