Return-Path: X-Original-To: apmail-metamodel-dev-archive@minotaur.apache.org Delivered-To: apmail-metamodel-dev-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 955A410EF7 for ; Wed, 16 Jul 2014 21:01:17 +0000 (UTC) Received: (qmail 95962 invoked by uid 500); 16 Jul 2014 21:01:17 -0000 Delivered-To: apmail-metamodel-dev-archive@metamodel.apache.org Received: (qmail 95926 invoked by uid 500); 16 Jul 2014 21:01:17 -0000 Mailing-List: contact dev-help@metamodel.incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@metamodel.incubator.apache.org Delivered-To: mailing list dev@metamodel.incubator.apache.org Received: (qmail 95912 invoked by uid 99); 16 Jul 2014 21:01:17 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 16 Jul 2014 21:01:17 +0000 X-ASF-Spam-Status: No, hits=1.5 required=5.0 tests=HTML_MESSAGE,RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of i.am.kasper.sorensen@gmail.com designates 209.85.212.169 as permitted sender) Received: from [209.85.212.169] (HELO mail-wi0-f169.google.com) (209.85.212.169) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 16 Jul 2014 21:01:14 +0000 Received: by mail-wi0-f169.google.com with SMTP id n3so6385701wiv.4 for ; Wed, 16 Jul 2014 14:00:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=OAzRpLOwhQbzpE+95WtwhBb1U/Jj0qAWoQgHdB86BdQ=; b=PL4bmlk8X0hD6Xpu5LLUkYgdSd2fKYiJ3rFTZ4JWSa8+UV01M9Qtp99TQrm1LKq3kI m2M/+6Z9gG7/MVAM/Ov+oWmKwo+1tGXeqlZQlANI9VjCznv/pjMAHmeE8ARGtgLWPiuh Y34I9aENKHeZu+z7R1Oecrfg7hqioyQ4DoMVy87jskkb/2chDX8opzfGhMOG3jaU7y3s gszLtJ92s7Cus2TcLIGtOduhixaO2ZF8kP89BZLnqNMFNV8pFyiusX7SWAOFX8X8Bdcq oIwM3seq1XQAAOrjDZl/GSwVNvFSnmjc4N8ySxgiJSFm36vjY2nGAbItULn8zm0xNYvp MMlQ== MIME-Version: 1.0 X-Received: by 10.180.12.33 with SMTP id v1mr17025833wib.0.1405544449871; Wed, 16 Jul 2014 14:00:49 -0700 (PDT) Received: by 10.194.163.7 with HTTP; Wed, 16 Jul 2014 14:00:49 -0700 (PDT) In-Reply-To: References: Date: Wed, 16 Jul 2014 23:00:49 +0200 Message-ID: Subject: Re: Create a CSV in a empty file From: =?UTF-8?Q?Kasper_S=C3=B8rensen?= To: "dev@metamodel.incubator.apache.org" Content-Type: multipart/alternative; boundary=001a11c24092a6947e04fe55d189 X-Virus-Checked: Checked by ClamAV on apache.org --001a11c24092a6947e04fe55d189 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: quoted-printable Hi there, There is a little known trick to get around that issue, so I guess it's a very fair question. The trick is to first do a drop table, and then a new create table. When MM is initialized with an existing empty file, it will determine that there IS a table, since the file is there, but that table has no columns, because the file does not define any columns. Maybe it's a bit silly - I actually think that's worth discussing ... But the reason it is there is I guess to indicate that at least the file is there, it's not a non-existing file (in which case there would not be any table). Best regards, Kasper 2014-07-16 21:37 GMT+02:00 J=C3=BAnior : > Hi, > > I'm trying to use the metamodel to write on an empty csv, > > But I'm getting errors saying that there is no column. > > I was able to do that calling create table with a different name from the > file. > Then added the columns. > > I worked, but it created the header line with the column names, would it = be > possible to do that without adding the column names in the csv file? > > Att. > -- > Francisco Ribeiro > *SCEA|SCJP|SCWCD|IBM Certified SOA Associate* > --001a11c24092a6947e04fe55d189--