跳至內容
選單
此問題已被標幟
2 回覆
4562 瀏覽次數

Hi,

I would like to know if there is a way and how to proceed to programmatically know what is the current database name from within module scripts.

Thanks.

頭像
捨棄
最佳答案

Try this code,

    `dbName = self._cr.dbname`

頭像
捨棄
最佳答案

Hi please try this:-

>> cursor_postgres.execute("select current_database()")

頭像
捨棄
相關帖文 回覆 瀏覽次數 活動
4
4月 24
2217
2
2月 23
6306
Database Odoo 已解決
1
3月 18
3439
1
3月 17
3413
1
8月 16
5037