How to convert string to date?
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
- CRM
- e-Commerce
- 会計
- 在庫
- PoS
- プロジェクト
- MRP
この質問にフラグが付けられました
1
返信
22791
ビュー
How to convert string to date?
Hello Giezel Esteves,
Here is the python code to convert string to date.
import datetimeHere "24052010" is string. you can pass a variable at here.
datetime.datetime.strptime('24052010', '%d%m%Y').date()
関連投稿 | 返信 | ビュー | 活動 | |
---|---|---|---|---|
|
3
7月 23
|
27893 | ||
|
2
6月 22
|
6133 | ||
|
2
9月 21
|
5249 | ||
|
1
11月 20
|
8518 | ||
|
2
3月 19
|
6508 |
Try this: https://learnopenerp.blogspot.com/2021/07/how-to-use-and-convert-date-field-format-odoo.html