Menu

#73 [Python] The format of Cubrid Date/Time/Timestamp string are different from Python's

open
nobody
None
5
2012-02-03
2012-02-03
Jira Trac
No

# Brief:
## The format of Cubrid Date/Time/Timestamp string are different from Python's Date/Time format
# Test Steps:
## use CUBRIDdb.Date(1,1,1) to generate a date type data
## use CUBRIDdb.Date(0,0,0) to generate a time type data
## use CUBRIDdb.Timestamp(1,1,1 0,0,0) to generate a timestamp type data
# Result
## Expect result: 0001-01-01,00:00:00,0001-01-01 00:00:00
## Actual result: 1-1-1,0:0:0,1-1-1 0:0:0
{noformat}
import CUBRIDdb
def test_cubrid_date():
date = CUBRIDdb.Date(1,1,1)
time = CUBRIDdb.Time(0,0,0)
timestamp = CUBRIDdb.Timestamp(1,1,1,0,0,0)
print date
print time
print timestamp
if __name__ == '__main__':
test_cubrid_date()
{noformat}

Discussion

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.