I really have problem in my SQL Anywhere. I'm using SQL Anywhere 16.
when i write something like this example :
when it save and then i look again, it being like this
SQL Anywhere always add double quotation marks (").
where is the setting which requires that marks or to remove the marks?
I hope from this forum i will find the answer.
SQL Anywhere saves stored procedure source code in one or two formats: it always saves a slightly mangled version in SYSPROCEDURE.proc_defn (which is what you are seeing), and optionally saves the original version in SYSPROCEDURE.source.
Here is a demonstration...
CREATE PROCEDURE p() BEGIN declare var_x int; declare var_y int; select dateformat ( current date, 'dd-mm-yyyy' ) as tgl , substr ('123456', 1, 3) as col2; END; SELECT proc_defn, source FROM SYSPROCEDURE WHERE proc_name = 'p'; create procedure "DBA"."p"() begin declare "var_x" integer; declare "var_y" integer; select "dateformat"(current date,'dd-mm-yyyy') as "tgl","substr"('123456',1,3) as "col2" end create PROCEDURE p() BEGIN declare var_x int; declare var_y int; select dateformat ( current date, 'dd-mm-yyyy' ) as tgl , substr ('123456', 1, 3) as col2; END
This PRESERVE_SOURCE_FORMAT controls whether or not SYSPROCEDURE.source will be filled. To see your current setting:
SELECT CONNECTION_PROPERTY ( 'PRESERVE_SOURCE_FORMAT' ); CONNECTION_PROPERTY('PRESERVE_SOURCE_FORMAT') 'On'
To set the option...
SET OPTION PUBLIC.PRESERVE_SOURCE_FORMAT = 'ON';
answered 30 May '15, 07:45