Getting error "Execute Query" activity

Hi,

Could anyone help me resolve this error ?

Thanks in Advance

2 Likes

@Abubakkar

Try to execute query manually in DB platforms.

Regards,
A Manohar

2 Likes

Yes, I tried already

@Abubakkar

Are u getting results…?

1 Like

yes it’s working fine. but i couldn’t able to run inside of execute query activity

@Abubakkar

Can you post your query here?

1 Like

Kindly remove the extra blank space while mentioning here, because we are passing the query as a string, which should not have any space or blank lines in between

Cheers @Abubakkar

1 Like

Yeah, I removed all extra blank spaces. but since i getting the same error.

1 Like

Fine
along the query itself were we able to find any red curly lines under any of the string in the query…if so we need to check whether we have missed any symbols like double quotes or is there any extra space or comma or brackets
its purely with the query buddy
we need to validate that
Cheers @Abubakkar

1 Like

Thanks @Palaniyappan. i checked all red curly lines, symbols, double quotes, comma and brackets. it’s correct only.
Actually My sql query is running perfectly in SQL yog studio. but the thing is I couldn’t able to run in using inside of execute query activity.
Should I check database connection activity?

no buddy
if thats the issue it would have shown us
and its very clear that the issue here is with the query, where the sql server will parse those sql statement property even if it miss out certain alignment
if possible can i have a view on tat query if possible
Cheers @Abubakkar

@Abubakkar

write your query in write line activity
and compare the output string with the query you executed in DB manually

1 Like

Thanks @Karun

Yeah, but Since I getting same error.

“END OF EXPRESSION EXPECTED”

then the issue is because of missing string concatenation or missing any single quote
kindly recheck once

1 Like

i got the issue
its because of this line
image

Cheers @

1 Like

Thank you @Palaniyappan.
Should I delete this ?

image

I got this error

1 Like

Let’s do one thing
Put this sql statement in a text file
—use READ TEXT FILE activity and pass the file path of the .txt file and get the output with a variable of type string named str_input
—now use this EXECUTE QUERY activity and mention the str_input in query section as input

Cheers @Abubakkar

3 Likes

image

Error resolved but output not came:smiley:

1 Like

Yes It’s working fine Thank you @Palaniyappan

1 Like

Awesome
Cheers @Abubakkar

1 Like