0

So I have this SQL statement that I am calling within the dbms_xmlgen.getxml function and I am receiving the error ORA-01704: string literal too long.

I believe the issues is that the SQL statement I am calling within the function is just too big. I've seen lots of forum posts talking about a 4000 character limit and my statement is currently sitting at 4753 characters. In fact my statement consists of two statements UNION'd together, if I take out one of them, which in essence halves my statement then it runs fine.

I cant make my statement 753 characters smaller, so is there anything I can do to get round this 4000 character limit?

If it helps I'm on Oracle 11g, release 11.2.0.2.0

Thanks in advance

Batad
  • 15
  • 5

1 Answers1

0

Turn your query into a view, and use that.

Neil Barsema
  • 201
  • 1
  • 4
  • Hi. Thanks for this. The same painfully obvious solution came to me during the weekend! – Batad Mar 14 '16 at 08:33