Find() function matching date values

Find() function matching date values

I am trying to use the find function using three char expressions and one date expression. I am using PB 6.5 with Oracle as the database. The following is my command string:

ll_RuleRow = dw_rule_modifiers.Find("modifier_code  = '" + ls_modifier +"'"+ & "AND state_abbr = '" + ls_state +"'"+ & " AND coverage_type = '" + ls_cov +"'"+ & " AND String(effective_date) = " + & " String(To_Date( '" + ls_Effective_Date + "',   'MM/DD/YYYY HH24:MI:SS'))", +& 1, dw_rule_modifiers.RowCount())

I am having trouble getting the effective_date to work with the function. If I take the lines for the effective_date out, the function works. However, I need the effective_date to be in the function.

The problem you are having is that you are using an Oracle function in your Powerscript. You need to use only PowerScript functions in the find command. Replace the Data portion of the code like:

" AND String( effective_date, 'YYYY/MM/DD' ) = '" + String( ld_Effective_date, 'YYYY/MM/DD' )  + "'"

This should now work.

Share the Post:
data observability

Data Observability Explained

Data is the lifeblood of any successful business, as it is the driving force behind critical decision-making, insight generation, and strategic development. However, due to its intricate nature, ensuring the

Heading photo, Metadata.

What is Metadata?

What is metadata? Well, It’s an odd concept to wrap your head around. Metadata is essentially the secondary layer of data that tracks details about the “regular” data. The regular

XDR solutions

The Benefits of Using XDR Solutions

Cybercriminals constantly adapt their strategies, developing newer, more powerful, and intelligent ways to attack your network. Since security professionals must innovate as well, more conventional endpoint detection solutions have evolved