How can Matches the DT Values with verify Prefex and Suffix of Char

Hi,
I want to check the Filter is working correctly in the Web Page

image

In the Serial We can Enter the Combination of Value
Ex:
image
Enter Like This
The Results of DataTable Values are
image

The (Asteric ) is the Give the Values Before (1G)

In This Case I Create a Test Cases for Verfiy the Filter DT only the Values of before(1G)

And Also In the Serial Type Box We can also Enter the Values like
For Ex:
Prefix Value(ZS(Asteric Sysmbol)) Its Filters The DT Values
(
ZS2932ids
ZS9fjo333
) Like That

I Try this Expression
image

But its Fails,

Im Using Matches Activity First Time

Can u Suggested the Correct Pattern In ths Matchs For My WorkFlow?

Hi,

Can you share an expression at Input property of Matches?
I suppose it should be as the following. Can you try this?

String.Join(vbCrLf,ExtractDataTable.AsEnumerable.Select(Function(r) r(0).ToString()))

Or we can also check it using FilterDataTable activity as the following.

image

Regards,

Hi @Yoichi ,

In the web page In the Serial Tab Enters the Value its Filter the Data Table

I just want to Verify the DT is equals as per the Serial Table Values

I modify few thing in the workflow

The IsMatch Full Expression
image

verfiy the DT with the IsMatch activity the results is True or False

But i Run this the results was False

Can u plz tell about my workflows are Correct And Suggests a Correct Expression for ISMatch Activity

hi,

Can u plz rply for this?

HI @Rajiduraikannu_Santhosh_G

As $ at last of ZS

Regards
Sudharsan

HI @Sudharsan_Ka ,

thanks you for ur correction,

But i run the workflow the Results was False but the Check the DataTable Filter was Correct.

If I change the verify activity into the for each loop its work correct or not? Can u plz suggestion the correct step for this?

Regards,
Santhosh

Hi,
Can u rply for this?

Hi,

Can you share your workflow as file, if possible?

Regards,

Hi @Rajiduraikannu_Santhosh_G
use below query to filter only start with ZS in the datatable column
dt.select("ColumnName like 'ZS%'").CopyToDataTable()

If you want to dynamic use below
string variable Val=β€œ*1G”
dt.select("ColumnName like '"+Val.ToString().Replace("*","%")+"'").CopyToDataTable()

Regards,
Arivu

Thanks for ur suggestion @arivu96 ,

I want dynamic its so useful for me,
I Try this method

I got this Error
image

Hi ,

Like keyword is missing in the syntax.

DT.Select("Serial like '"+GetSerial.ToString().Replace("*","%")+"'").CopyToDataTable()

Regards,
Arivu

Hi @arivu96 ,

I correct the code and run the workflow

image

In the Log Message No Values Display?

In log message what you have given.

Regards,
Arivu

This code i set in the log message fo check the values

The above code will return the datatable as output. if you want to print the table, use output datatable activity and print the output in log message

Regards,
Arivu

Can u explain about this, how can i verify with the datatable?

Hi @Rajiduraikannu_Santhosh_G ,
Use output data table activity

Regards,
Arivu

1 Like

Hi @arivu96 ,

image

Can u plz suggested that this format is correct or not?

hi @arivu96 ,
can u rply for this?

Why are you using Regex pattern here.