summaryrefslogtreecommitdiff
path: root/sql/sql_class.cc
diff options
context:
space:
mode:
authorAlexander Barkov <bar@mysql.com>2009-10-21 15:48:22 +0500
committerAlexander Barkov <bar@mysql.com>2009-10-21 15:48:22 +0500
commitdcb8bb23c29172949781f5214b8222505752de70 (patch)
treed2522e7182d47f0be16e18e95d3830f7ff496ce0 /sql/sql_class.cc
parent52701ff3277d6641994e6b76d84bb5903af48d59 (diff)
parentde7d1abe9386c2e9df1a8c5f3b95f3cd57cc6c9f (diff)
downloadmariadb-git-dcb8bb23c29172949781f5214b8222505752de70.tar.gz
Merging mysql-next-mr-merge to mysql-next-mr.
Diffstat (limited to 'sql/sql_class.cc')
-rw-r--r--sql/sql_class.cc8
1 files changed, 6 insertions, 2 deletions
diff --git a/sql/sql_class.cc b/sql/sql_class.cc
index 24d1dc5d3a9..4ed25b03ed7 100644
--- a/sql/sql_class.cc
+++ b/sql/sql_class.cc
@@ -1617,13 +1617,17 @@ bool select_result::check_simple_select() const
static String default_line_term("\n",default_charset_info);
static String default_escaped("\\",default_charset_info);
static String default_field_term("\t",default_charset_info);
+static String default_xml_row_term("<row>", default_charset_info);
-sql_exchange::sql_exchange(char *name,bool flag)
+sql_exchange::sql_exchange(char *name, bool flag,
+ enum enum_filetype filetype_arg)
:file_name(name), opt_enclosed(0), dumpfile(flag), skip_lines(0)
{
+ filetype= filetype_arg;
field_term= &default_field_term;
enclosed= line_start= &my_empty_string;
- line_term= &default_line_term;
+ line_term= filetype == FILETYPE_CSV ?
+ &default_line_term : &default_xml_row_term;
escaped= &default_escaped;
cs= NULL;
}