cancel
Showing results for 
Search instead for 
Did you mean: 

Error on DATE in sapui5

Former Member
0 Kudos

Hi guys,

i am getting error while using DATE column in odata filter url,

here is my sample code below,

Am getting error like this

Can anyone help me to solve this error,

Thanks & Regards,

Bharath

Accepted Solutions (1)

Accepted Solutions (1)

kedarT
Active Contributor
0 Kudos

Hi Bharath,

Hope this example helps you - http://jsbin.com/qowuxe/3/edit?js,output

Former Member
0 Kudos

hi kedar,

Thanks for yuor time and reply,

Am using XSODATA file, and getting an error like this,

And my sample piece of code is like this

So can you help me to solve this.??

Thanks & Regards,

Bharath

kedarT
Active Contributor
0 Kudos

Hi Bharath,

I you need to convert your date format from YYYY-MM-DD to ISO format using javascript function toISOString() and oData has DateTIme data type.

In my example look at the DatePicker's change event on how input date is converted to the format which the oData and used this value for filtering.

Hope this helps.

Former Member
0 Kudos

Hi kedar,

Thank you so much for reply,

the issue is solved for me

Did a mistake in  my coding only

Thanks once again

Regards,

Bharath

kedarT
Active Contributor
0 Kudos

Hi Bharath,

Please mark the relevant post as helpful and put in the right answer so that it helps others facing similar issues.

Regards,

Kedar

Former Member
0 Kudos

Hi guys,

Because of the Dimension in my coding part, the chart was not rendering..

So we need to specify the exact axis for the dimensions and measures in our UI5 code.

In your code, use "axis : 1" for the x axis and "axis : 2" for the y axis.

Regards,

Bharath

Answers (0)