Today I encountered this nice SP2-0027 Oracle error. In short, there is a limitation in sqlplus that does not allow you to execute any commands longer than 2499 chars. There are useful hints for solving this error here, but unfortunately all of them are not good for me. The thing is, my long string was a “CREATE VIEW” statement that collected the report data across 4 tables who each had about 50-100 fields. So the statement itself was about 8kb in size. And it was a part of my automated deploy process where I had no place for “execute that manually with sql developer”.
Now I admit, after analyzing the statement I figured out I don’t need all of these fields and shortened the statement to pass the bar but really, Oracle, are you kidding me? Why in 2015 there are such limitations on the official command-line tool? Of course I can take any JDBC/ADO/PDO adapter and simply execute that statement through it or even use Flyway, but I just wonder if this means that the era of sqlplus comes to an end and nobody actively develops it anymore.