0

I have issue in running the following sql:

update personal_view test set session_state="<script type="text/javascript">
alert (mstrApp.sessionState);
</script>"

I know it is because of the double quotes within the double quotes and symbols like ; / < and > in the sql.

Any idea on how to fix this issue?

Yuck
  • 49,664
  • 13
  • 105
  • 135
Jude
  • 87
  • 1
  • 9

1 Answers1

2

Try:-

update personal_view test set session_state='"<script type="text/javascript">'

In most SQL dialects strings are wrapped in single quotes double quotes have no special meaning inside a string.

James Anderson
  • 27,109
  • 7
  • 50
  • 78