Export from QGIS to existing SpatiaLite .sqlite database

732 views
Skip to first unread message

Paulo Eduardo Cardoso

unread,
Jan 18, 2011, 3:46:22 PM1/18/11
to SpatiaLite Users
Can we export vector data from Qgis into an existing *.sqlite database?

jefe rodolfo pereira da silva

unread,
Jan 18, 2011, 3:53:04 PM1/18/11
to spatiali...@googlegroups.com
Pode sim Paulo.

Um abraço,

2011/1/18 Paulo Eduardo Cardoso <pauloed...@gmail.com>
Can we export vector data from Qgis into an existing *.sqlite database?

--
You received this message because you are subscribed to the Google Groups "SpatiaLite Users" group.
To post to this group, send email to spatiali...@googlegroups.com.
To unsubscribe from this group, send email to spatialite-use...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/spatialite-users?hl=en.




--
Jefe Rodolfo Silva
Analista de SIG
CONSIS-Consultoria e Sistemas Ltda.
65 3301-3276
65 8154-6830

Paulo Eduardo Cardoso

unread,
Jan 19, 2011, 2:59:16 AM1/19/11
to SpatiaLite Users
Hi,

Any suggestion? I'm not being able so far.

Paulo

On 18 Jan, 15:53, jefe rodolfo pereira da silva
<jeferodo...@gmail.com> wrote:
> Pode sim Paulo.
>
> Um abraço,
>
> 2011/1/18 Paulo Eduardo Cardoso <pauloeducard...@gmail.com>
>
> > Can we export vector data from Qgis into an existing *.sqlite database?
>
> > --
> > You received this message because you are subscribed to the Google Groups
> > "SpatiaLite Users" group.
> > To post to this group, send email to spatiali...@googlegroups.com.
> > To unsubscribe from this group, send email to
> > spatialite-use...@googlegroups.com<spatialite-users%2Bunsu...@googlegroups.com>
> > .

Noli Sicad

unread,
Jan 19, 2011, 4:16:00 AM1/19/11
to spatiali...@googlegroups.com
Hi Paulo.

Save the vector layer in QGIS. Open a console / terminal, open the
spatialite database and .loadshp command to load it in existing
spatialite database.

I just try it. It works.

Regards, Noli

> spatialite-use...@googlegroups.com.

Paulo Eduardo Cardoso

unread,
Jan 19, 2011, 4:34:40 PM1/19/11
to SpatiaLite Users
Hi Noli,
You mean the Python console?
Have you a sample code for this? This is completely new for me.
By now I'm doing this using SpatiaLite GUI | Load Shapefile utility
but I would like to do it from inside QGIS.
Regards,
Paulo
On Jan 19, 9:16 am, Noli Sicad <nsi...@gmail.com> wrote:
> Hi Paulo.
>
> Save the vector layer in QGIS. Open a console / terminal, open the
> spatialite database and .loadshp command to load it in existing
> spatialite database.
>
> I just try it. It works.
>
> Regards, Noli
>
> On 1/19/11, Paulo Eduardo Cardoso <pauloeducard...@gmail.com> wrote:
>
>
>
>
>
>
>
> > Hi,
>
> > Any suggestion? I'm not being able so far.
>
> > Paulo
>
> > On 18 Jan, 15:53, jefe rodolfo pereira da silva
> > <jeferodo...@gmail.com> wrote:
> >> Pode sim Paulo.
>
> >> Um abraço,
>
> >> 2011/1/18 Paulo Eduardo Cardoso <pauloeducard...@gmail.com>
>
> >> > Can we export vector data from Qgis into an existing *.sqlite database?
>
> >> > --
> >> > You received this message because you are subscribed to the Google
> >> > Groups
> >> > "SpatiaLite Users" group.
> >> > To post to this group, send email to spatiali...@googlegroups.com.
> >> > To unsubscribe from this group, send email to
> >> > spatialite-use...@googlegroups.com<spatialite-users%2Bunsubscrib e...@googlegroups.com>

Noli Sicad

unread,
Jan 19, 2011, 4:49:32 PM1/19/11
to spatiali...@googlegroups.com, pauloed...@gmail.com
Hi Paulo.

No. It is console terminal. Not a python console.

Sample code:

C:\spatialite-tools-win-x86-2.4.0\bin>spatialite VicMap20.sqlite

spatialite> .nullvalue NULL
spatialite> .headers on
spatialite> .mode column
spatialite> .tables

spatialite> .loadshp PROPERTY_MP property_mp CP1252 4326;

~~~~~~~~~
Use python console to load shapefile.

http://groups.google.com/group/spatialite-users/browse_thread/thread/4bcdafd93f3c9c93/805008d4d6032583

> but I would like to do it from inside QGIS.

Not possible as the moment. You can create a QGIS python plugin with
above information.

Noli

Alex Mandel

unread,
Jan 20, 2011, 2:16:14 AM1/20/11
to spatiali...@googlegroups.com
Last I heard Gary Sherman was working on supporting writing back to
spatialite in QGIS. It would probably be best to check in with him and
the QGIS developers since this is a QGIS feature request, there's
nothing from the spatialite side that prevents it from happening.

It might also be solved when GDAL/OGR 1.8 comes out with the next
release of QGIS as I believe that too supports read/write from spatialite.

Thanks,
Alex

On 01/19/2011 01:34 PM, Paulo Eduardo Cardoso wrote:
> Hi Noli,
> You mean the Python console?
> Have you a sample code for this? This is completely new for me.
> By now I'm doing this using SpatiaLite GUI | Load Shapefile utility
> but I would like to do it from inside QGIS.
> Regards,
> Paulo
> On Jan 19, 9:16 am, Noli Sicad <nsi...@gmail.com> wrote:
>> Hi Paulo.
>>
>> Save the vector layer in QGIS. Open a console / terminal, open the
>> spatialite database and .loadshp command to load it in existing
>> spatialite database.
>>
>> I just try it. It works.
>>
>> Regards, Noli
>>
>> On 1/19/11, Paulo Eduardo Cardoso <pauloeducard...@gmail.com> wrote:
>>
>>
>>
>>
>>
>>
>>
>>> Hi,
>>
>>> Any suggestion? I'm not being able so far.
>>
>>> Paulo
>>
>>> On 18 Jan, 15:53, jefe rodolfo pereira da silva
>>> <jeferodo...@gmail.com> wrote:
>>>> Pode sim Paulo.
>>

>>>> Um abra�o,

Paulo Eduardo Cardoso

unread,
Jan 20, 2011, 2:49:17 AM1/20/11
to SpatiaLite Users
Great news. Thanks
Reply all
Reply to author
Forward
0 new messages