User Tools

Site Tools


informatica:linux:bbdd:sqlite

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
informatica:linux:bbdd:sqlite [2013/07/03 09:02] – external edit 127.0.0.1informatica:linux:bbdd:sqlite [2015/08/20 13:37] (current) javi
Line 10: Line 10:
   create table job(date integer, position text, area text, company text, primary key(position,area,company));   create table job(date integer, position text, area text, company text, primary key(position,area,company));
   .exit   .exit
 +  
 +* Volcar base de datos
 +
 +  sqlite3 /ruta/base_datos.db .dump
 +  
 +* Describir una tabla
 +
 +  sqlite3 /ruta/base_datos.db .schema tabla_1
 +
 +* Crear base de datos desde archivo
 +
 +  sqlite3 /ruta/base_datos.db < base_datos.sql
 +
 +<code>
 +DROP TABLE IF EXISTS RADIO;
 +
 +CREATE TABLE RADIO (
 +        id TEXT NOT NULL PRIMARY KEY,
 +        name TEXT NOT NULL,
 +        description TEXT,
 +        url TEXT NOT NULL,
 +        longitude REAL,
 +        latitude REAL,
 +        altitude REAL
 +);
 +
 +INSERT INTO "RADIO" VALUES('1', 'Contrabanda FM', 'Radio libre y no comercial de Barcelona', 'http://www.porticoluna.com:8000/contrabanda', '2.174580', '41.380289', '');
 +</code>
informatica/linux/bbdd/sqlite.1372842169.txt.gz · Last modified: 2015/04/13 20:19 (external edit)