how to change varhar in date?

Good day, There was such a problem. There is a stored procedure in which the varhar is used, but I can’t use it because the class does not have it, is it possible to somehow convert the varhar into a date?

deadsploid's picture
Joined: Nov 9 2022 - 1:06am
Last seen: 2 weeks 2 days ago

What Database are you using?? maybe a CAST(param AS DATE) works

eduardo_rhamos - 2 months 5 days ago

hello, i use mssql

deadsploid - 2 months 1 day ago

2 Answers:

Hello,

From your description it looks like you defined date field datatype as varchar in store proc. Ideally date field datatype should be DATE.

May be you can try to change datatype to DATE in store proc. 

jphadtar's picture
1073
Joined: Mar 20 2022 - 10:51pm
Last seen: 2 days 10 hours ago

hello, not exactly, I defined a varchar as a date, since in jasperstudio I don’t have a varchar in my classes.

deadsploid's picture
Joined: Nov 9 2022 - 1:06am
Last seen: 2 weeks 2 days ago
Feedback
randomness