<html>
<head>
<style><!--
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
font-size: 10pt;
font-family:Tahoma
}
--></style>
</head>
<body class='hmmessage'>
Micha, Richard.<br><br><div><div><span class="Apple-style-span" style="font-size: 13.3333px; ">Thank you very much for the help.</span></div><div><div><br></div><div><br><div><br>Pablo Torres Carreira
<br><br><br><br>> Date: Fri, 22 Oct 2010 08:34:50 +1100<br>> From: rchirgwin@ozemail.com.au<br>> To: grass-user@lists.osgeo.org<br>> Subject: [GRASS-user] Re: Change database type (Micha Silver)<br>> <br>> On 22/10/10 8:12 AM, grass-user-request@lists.osgeo.org wrote:<br>> > Send grass-user mailing list submissions to<br>> >         grass-user@lists.osgeo.org<br>> ><br>> > To subscribe or unsubscribe via the World Wide Web, visit<br>> >         http://lists.osgeo.org/mailman/listinfo/grass-user<br>> > or, via email, send a message with subject or body 'help' to<br>> >         grass-user-request@lists.osgeo.org<br>> ><br>> > You can reach the person managing the list at<br>> >         grass-user-owner@lists.osgeo.org<br>> ><br>> > When replying, please edit your Subject line so it is more specific<br>> > than "Re: Contents of grass-user digest..."<br>> ><br>> ><br>> > Today's Topics:<br>> ><br>> > 1. Change database type (Pablo Carreira)<br>> > 2. v.in.ogr and g.region trouble coordenate (Ricardo Rodr?guez)<br>> > 3. Re: Change database type (Micha Silver)<br>> > 4. Re: v.in.ogr and g.region trouble coordenate (Micha Silver)<br>> > 5. nviz_cmd problem winGrass6.5 - 7.0 (M.Onur Kurum)<br>> ><br>> ><br>> > ----------------------------------------------------------------------<br>> ><br>> > Message: 1<br>> > Date: Thu, 21 Oct 2010 15:23:15 -0200<br>> > From: Pablo Carreira<pablotcarreira@hotmail.com><br>> > Subject: [GRASS-user] Change database type<br>> > To:<grass-user@lists.osgeo.org><br>> > Message-ID:<SNT114-W15AB33CF89A9A96DFBD9B5D65D0@phx.gbl><br>> > Content-Type: text/plain; charset="iso-8859-1"<br>> ><br>> ><br>> > Hi,<br>> ><br>> > I have many vectors with tables and now I want to change my database from sqlite to pgsql.I ran db.connect. And now I need to copy all the tables from sqlite to pgsql.Is there an easy way to do that?<br>> > Thanks.<br>> > Pablo Torres Carreira<br>> ><br>> ><br>> >                                           <br>> > -------------- next part --------------<br>> > An HTML attachment was scrubbed...<br>> > URL: http://lists.osgeo.org/pipermail/grass-user/attachments/20101021/4ad2cda2/attachment-0001.html<br>> ><br>> > ------------------------------<br>> ><br>> > Message: 2<br>> > Date: Thu, 21 Oct 2010 15:19:17 -0500<br>> > From: Ricardo Rodr?guez<ricardorodot02@gmail.com><br>> > Subject: [GRASS-user] v.in.ogr and g.region trouble coordenate<br>> > To: grass-user@lists.osgeo.org<br>> > Message-ID:<br>> >         <AANLkTi=sUMPrB-4VxP=S8xjfT=Oj1PGzuaHe03EXgCfG@mail.gmail.com><br>> > Content-Type: text/plain; charset="iso-8859-1"<br>> ><br>> > hello.<br>> > how to make g.region and v.in.ogr use the same projection that an incoming<br>> > file. since at run-d g.region v.in.ogr and maintaining the coordinates but<br>> > not the coordinate system, given the same coordinate system of the lease,<br>> > what should I do to keep your incoming file coordinate system .<br>> ><br>> ><br>> > thanks for your help and attention<br>> ><br>> > Ricardo Rodríguez<br>> > Univalle<br>> > -------------- next part --------------<br>> > An HTML attachment was scrubbed...<br>> > URL: http://lists.osgeo.org/pipermail/grass-user/attachments/20101021/3ae60005/attachment-0001.html<br>> ><br>> > ------------------------------<br>> ><br>> > Message: 3<br>> > Date: Thu, 21 Oct 2010 22:38:01 +0200<br>> > From: Micha Silver<micha@arava.co.il><br>> > Subject: Re: [GRASS-user] Change database type<br>> > To: Pablo Carreira<pablotcarreira@hotmail.com><br>> > Cc: grass-user@lists.osgeo.org<br>> > Message-ID:<4CC0A4A9.2@arava.co.il><br>> > Content-Type: text/plain; charset="iso-8859-1"<br>> ><br>> > On 10/21/2010 07:23 PM, Pablo Carreira wrote:<br>> >> Hi,<br>> >><br>> >><br>> >> I have many vectors with tables and now I want to change my database<br>> >> from sqlite to pgsql.<br>> >> I ran db.connect. And now I need to copy all the tables from sqlite to<br>> >> pgsql.<br>> >> Is there an easy way to do that?<br>> >><br>> > Once you've set the database connection params, then g.copy will create<br>> > a new vector with the attributes pushed into the new database. So you<br>> > could loop thru all vectors something like:<br>> > for v in `g.mlist vect`; do<br>> > g.rename vect=$v,$v_sqlite # rename to temporary name<br>> > g.copy vect=$v_sqlite,$v # copy back to original name, but<br>> > pgsql tables will be created<br>> > done<br>> ><br>> > If everything looks good, then you can remove all the vectors *_sqlite:<br>> > g.remove vect=`g.mlist vect sep=, pat="*_sqlite"`<br>> ><br>> >> Thanks.<br>> >><br>> >> Pablo Torres Carreira<br>> >><br>> >><br>> >><br>> >> This mail was received via Mail-SeCure System.<br>> >><br>> >><br>> >> _______________________________________________<br>> >> grass-user mailing list<br>> >> grass-user@lists.osgeo.org<br>> >> http://lists.osgeo.org/mailman/listinfo/grass-user<br>> >><br>> >> This mail was received via Mail-SeCure System.<br>> >><br>> >><br>> >><br>> Alternatively, if you want to keep the two separate, create a new <br>> mapset, set the database connection in the new mapset, and copy the maps <br>> from old mapset to new.<br>> <br>> Hence, in the new mapset:<br>> <br>> for i in `g.list vect mapset=<oldmapset>`; do<br>> g.copy vect=$i"@<oldmapset",$i<br>> done<br>> <br>> Often if I am going to be working away from the MySQL server, I do this <br>> to create a copy with a dbf connection.<br>> <br>> Cheers,<br>> Richard<br>> ><br>> <br>> <br>> _______________________________________________<br>> grass-user mailing list<br>> grass-user@lists.osgeo.org<br>> http://lists.osgeo.org/mailman/listinfo/grass-user<br></div></div></div></div>                                            </body>
</html>