Forum Discussion

leebaldwin's avatar
leebaldwin
Helper I
3 years ago

DB2 validate/format date

Hello:

I have a large number of scripts that I am converting from a Viewpoint Sequel format that is using a DB2 connection and converting them to PowerBI. For the most part, I have been able to figure out the nuances between the DB2 code and the Power BI code. This is my first time working within PBI, but I am learning and driving to succeed in my new role.

 

I have come across a piece of code that I have tried everyway to figure out how to get PBI to do the same thing and I am not able to. 

 

CASE WHEN Valid_Date(o1odte ,'*MDY')=1 THEN CVTDATE(o1odte ,MDY) ELSE null END NAME(date1) COLHDG("DATE" "ORDERED") EDTCDE(4)

 

Is there a way to do this in Power BI during data import? 

2 Replies