ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "fanyun" <yun....@vtradex.com>
Subject problem to insert sql with chinese charactor
Date Thu, 09 Aug 2001 11:37:17 GMT
Hi:

I am a user of ant 1.3.    I use ant to install some of the user defined sql files into mysql
database.  I list this define as below.   

 The scripts works well with english sql files.   Some part of sql have chinese charactors.
 The chinese charactors are in a mess in database.  It seems that ant can not handle double
bytes. (The sql itsself can be installed into mysql correctly  by using    mysql < abc.sql)


Has anyone met this problem?





------------------The build.xml file-------------------------------

<target name="modeling">
    	<antcall target="insert-sql-file">
      		<param name="sqlFile" value="${model}/1-initmenu.sql"/>
    	</antcall>
 </target>
 	
    	 
<target name="insert-sql-file">
	<sql
		driver="${databaseDriver}"
		url="${databaseUrl}"
		userid="${databaseUser}"
		password="${databasePassword}"
		src="${sqlFile}"
		autocommit="true"
		onerror="continue"
	>
		<classpath refid="classpath"/>
	</sql>
</target>


------------------The sql file-------------------------------

insert into MENUITEM (ID, TITLE,CODE,PARENTCODE) values (2, '<some chinese Charactor>','010100','010000');





Mime
View raw message