[Zope-DB] Oracle DATE type question
Ben Avery
ben@thesite.org
Thu, 21 Nov 2002 12:05:19 +0000
you might be better not using the Oracle DATE type at all, and just
storing them as strings. If you store them in a format like
YYYY-MM-DDhh24:mi:ss, then they will still sort in date order.
Would this be possible, or would it be too much work to change the
stored procedures?
When using ZSQL methods to insert dates, you always have to use TO_DATE
from the Zope string, so there's a certain amount of work to be done
however you choose to do it.
Ben
Bo M. Maryniuck wrote:
> Hello, Oracle d00dz! ;-)
>
> Well. If I see, that some stored procedure requires type DATE within VARCHAR2
> and NUMBER, what shell I do to pass there a right DATE? Yes, I know, that it
> would be better to pass a string and then Oracle should convert by its own.
> But if you have dozen of packages where is hundreds of procedures and all
> they requires sometimes DATE -- then passing a string is not a soliution.
>
> So in which way I should pass a date?
>