Ver categorías

Cómo conectar SQLite a Google Sheets: transmitir en directo datos de una base de datos ligera

Conectar SQLite con Google Sheets

Obtenga datos de un SQLite archivo en Hojas de cálculo de Google

Abre tu base de datos SQLite en Google Sheets y actualízala cuando quieras. Sin subir archivos CSV, sin usar Apps Script, sin copiar y pegar. La primera vez solo te llevará unos diez minutos, y el plan gratuito lo incluye.

Aproximadamente 10 minutos No se necesita programar El archivo permanece donde está. Cualquier navegador, cualquier dispositivo
¿Tienes algún problema? Pregúntanos. Abrir Ayuda En Consultas de flujos (menú superior derecho → Soporte) y envíanos un mensaje. Personas reales lo leen, y «No sé qué me pide esta pantalla» es una pregunta perfectamente válida.

Lo que obtendrás al final

Logotipo de SQLiteUna hoja de cálculo de Google que muestra los resultados en tiempo real de una consulta SQL en tu archivo SQLite, con un botón que muestra las filas más recientes cada vez que cambian los datos. Algo así:

Las bases de datos SQLite son archivos únicos, que generalmente terminan en .db, .sqlite, .sqlite3Google Sheets no puede abrirlos, y la solución habitual es exportar un archivo CSV y volver a subirlo cada vez que cambian los datos. Query Streams evita este paso: un pequeño programa auxiliar lee el archivo donde ya se encuentra, y un complemento de Google Sheets le solicita las filas que necesitas. No es necesario que ambos programas estén en el mismo ordenador. El archivo puede estar en el ordenador de la oficina y tú puedes estar en cualquier lugar: en cualquier navegador y en cualquier dispositivo.

DÓNDE SE ENCUENTRA EL ARCHIVOel ordenador de la oficina, un servidor o el de casaTu archivo SQLitesales.db · se queda aquíAgente de flujos de consultaswhere it can open the fileFlujos de consultaenlace cifradopor internet · solo resultadosDONDEQUIERA QUE ESTÉSCualquier navegador: portátil, tableta, teléfono, ChromebookHojas de cálculo de GoogleLas filas llegan en una hoja
The Agent runs where it can open the file. Your sheet lives in Google’s cloud. Open it anywhere and the rows come to you.

Lo que necesitarás

Una cuenta de Query Streams

El plan gratuito es suficiente para esta guía. Regístrate en mi.querystreams.com.

The Agent on a computer that can open the file

Un pequeño programa que se ejecuta en segundo plano y lee el archivo cuando Google Sheets lo solicita. El paso 2 a continuación muestra dónde obtenerlo.

Tu archivo SQLite

Saber dónde está, por ejemplo C:\Datos\ventas.db o \\server\share\sales.db. If it lives in OneDrive, Dropbox or Google Drive, make sure it is synced to the Agent’s computer.

¿Qué ordenador recibe el Agente? The one where the file is, or one that can open it from a network share (see Reaching a file on a network share below). That computer needs to stay on. Google Sheets puede estar en cualquier lugarSe ejecuta en tu navegador, por lo que no se instala absolutamente nada donde lees los datos.

Conéctalo en cinco pasos

  1. Crea tu cuenta

    Ir a mi.querystreams.com y regístrese. Elija el Gratis Es un plan real, no una prueba, y abarca la conexión de tu archivo SQLite y la ejecución de consultas desde Google Sheets.

  2. Install the Agent on a computer that can open the file

    Iniciar sesión, abrir Descargar, and install the Agent for your system on the computer where the file is, or on one that can open it from a network share. It takes a minute and starts on its own from then on.

    ¿Por qué un programa pequeño en lugar de un controlador? The Agent is one install for Windows, Mac or Linux (about 85 MB on Windows, a little over 100 MB on Mac and Linux) that runs quietly in the background. It makes one outbound, encrypted connection to Query Streams, the same way a browser does, so you open no firewall port and set up no VPN. The file stays where it is, and the rows travel to wherever you are, across the internet if need be. The only thing on your side is the add-on.

    La página de descarga muestra Su clave de accesoPégalo en el Agente cuando te lo pida y espera a que aparezca la insignia. Conectado a flujos de consulta. Eso es lo único que debes hacer en el propio Agente.

    Si lo deseas, aquí tienes las guías completas: Ventanas, Impermeable, Linux.

  3. Apúntalo a tu archivo SQLite

    De vuelta en tu navegador, abre Agentes de datos (bajo Datos (en el menú superior). Su agente aparece allí. Haga clic. Agregar conector, elegir SQLitey rellenar:

    Nombre de la conexión
    Cualquier nombre que reconocerás más adelante, como base de datos de ventas.
    Ruta del archivo de la base de datos
    Where the SQLite file is: a path on the Agent’s computer, like C:\Data\sales.db, or a network path, like \\server\share\folder\sales.db, never a mapped drive letter such as S:. Use Browse to pick it.

    Haga clic en Probar la conexiónCuando se lee Conectado, haga clic GuardarLa conexión llega a su agente en cuestión de segundos.

    ¿La prueba falló? Usually the path has a typo, or it uses a mapped drive letter such as S:, which the Agent cannot see. Open the folder, copy the path from the address bar, and paste it in again. For a file on another computer, see Reaching a file on a network share abajo.

  4. See your data in Query Builder Opcional

    You can look at your SQLite file before Google Sheets is involved at all. Open Generador de consultas in the portal and pick the connection you just made. The Esquema tab lists your tables and columns, and clicking one puts its name in the editor, so you can write a query without remembering exact names. Click Ejecutar and the rows appear under Resultados. Query Builder is on every plan, Free included.

    On Business plans you can also ask Nova in plain English (“show me customers in the USA”) and it writes the SQL for you. When the query looks right, save it: from Personal Core up it shows in the add-on’s Saved Queries list, and on any plan you can copy the SQL into the next step.

  5. Agregar flujos de consultas a Google Sheets

    Abre cualquier hoja de cálculo de Google, ve a Extensiones → Complementos → Obtener complementos, buscar Flujos de consultay haga clic Instale. O instálelo directamente desde Flujos de consultas en el Marketplace de Google WorkspaceGoogle te pedirá que permitas el complemento; eso es normal.

    Después, aparece en cada Hoja de cálculo de Google que abres: un icono de Flujos de consulta en el panel lateral derecho, también listado en ExtensionesNo es necesario iniciar sesión por separado. Reconoce la cuenta de Google que ya estás usando, por lo que el correo electrónico debe ser el mismo que el de tu cuenta de Query Streams.

  6. Trae tu primera mesa

    Haga clic en el icono de Flujos de consulta en el panel lateral a la derecha de la hoja (o búsquelo en Extensiones). Elegir Transmisión de consultas y elige la conexión que acabas de hacer.

    Escriba la consulta que desea ejecutar. Esta extrae algunas columnas de una clientes mesa:

    Ejemplo · SQL
    SELECCIONAR customer_id, nombre, ciudad DE clientes ORDENAR POR nombre LIMITAR 100;

    Bajo Hoja de destino Seleccione la pestaña en la que deben aparecer las filas y, a continuación, haga clic. Ejecutar consultaLas filas aparecen en esa pestaña en uno o dos segundos. Haga clic en Ejecutar consulta nuevamente cada vez que los datos cambien y la pestaña se actualizará automáticamente.

    ¿No sabes SQL? Build it in Generador de consultas first and paste it here, or pick it from Saved Queries if you saved it.

Reaching a file on a network share

The Agent opens files as a background service, not as you, so a file on another computer needs one extra step. Which step depends on the computer the Agent runs on.

Ventanas

Type the network path, like \\servidor\recurso compartido\carpeta, never a mapped drive letter such as S:, which the Agent cannot see. If the share only lets in named people, click Service identity (the chip under the path) and store a login for that server: a company domain account, or an account made on the server itself with Domain left blank. The Agent then signs in to that server and reads the file there, and every connector on that Agent that reads the same server must use the same login. Without a login, it reads as its own service account, which a company domain sees as the computer itself. Step by step on Windows

Linux

Share logins stored in the Portal are not used on Linux: an administrator mounts the share on the Agent’s computer first, in a folder under /mnt o /medios de comunicación, because the Agent’s service cannot see /home o /run/user. In the connector, keep the \\servidor\recurso compartido path, which the Agent maps onto the mount, or type the mount path instead, such as /mnt/fileserver-shared/Accounts. How to mount a share on Linux

Impermeable

Share logins stored in the Portal are not used on a Mac: mount the share first from Terminal with sudo, in a folder under /Volumes, so the Agent’s background service can see it. In the connector, keep the \\servidor\recurso compartido path, which the Agent maps onto the mount, or type the mount path instead, such as /Volumes/fileserver-shared/Accounts. How to mount a share on a Mac

If the test cannot get to the share, look for these words in its result: unreachable means the Agent’s computer got no answer from the server. On Linux or a Mac, not mounted means the share still has to be mounted, and that message includes the exact mount command for your server.

SQLite file on a share? Dejar Read-Only (Immutable) ticked, as it is by default; reads then take a point-in-time view of the file without locks. SQLite cannot use its WAL mode over a network, so with that box unticked a WAL-mode database on a \\servidor\recurso compartido path is refused, and the test says it is a WAL-mode SQLite database.

Test failed on a share?

A Windows Agent signs in to the file server itself, so its test result can also say:

MensajeCausaArreglar
Access denied for the agent’s service account under the path, or Acceso denegado in the test resultThe share lets in named people only, and the Agent’s own Windows account is not one of them. Or the login stored for that server may not read this share.Haga clic en Service identity under the path and store a login that can read the share. If one is stored already, ask whoever runs the server to give that account read access.
the credentials were refusedThe server turned the stored login down: a typo, the wrong domain, or a password changed since it was saved.Click the account name under the path and type the login again; for an account made on the server itself, leave Domain blank. were refused moments ago means the Agent waits a minute before it tries that same login again, so the account is not locked out; saving a corrected password tries again straight away.
Another connector on this agent already signs in to, o Windows already holds a sign-in toThis Windows computer already signs in to that server as a different account, through another connector or another program. Windows allows one account per server.Store the login the other connector uses, or change it on every connector that reads that server. After Windows already holds a sign-in, the rest of the message says which account it is and what to do.
This agent build cannot sign in toThe Agent is an older version that cannot use stored share logins.Update the Agent, then test again.

Eso es todo. Tus datos están en la hoja de cálculo y se actualizan con un solo clic. Solo las filas que solicitaste salieron de tu red.

Buenos pasos a seguir

  • Guardar la consulta en el portal para que puedas ejecutarlo de nuevo con un solo clic, desde Google Sheets o Excel.
  • Agregar un filtro como un rango de fechas, de modo que la misma consulta pueda responder "este mes" sin necesidad de editarla.
  • Comparte los resultados con un colega. Ellos ven las filas, no tu archivo ni la ruta del archivo.

Preguntas que hace la gente

¿Es necesario que el archivo SQLite esté en el ordenador donde utilizo Hojas de cálculo de Google?

No. Only the Agent has to be able to open your SQLite file. Google Sheets runs in your browser on any device. Open the add-on with the same Google account and your connections are there.

¿Se sube mi archivo de base de datos a algún sitio?

No. The Agent reads the file where it sits and sends only the rows your query asks for. The file stays where it is.

¿Puede estar el archivo en OneDrive, Dropbox o Google Drive?

Sí, siempre y cuando esté sincronizado con el ordenador donde se ejecuta el Agente, de modo que este lo reconozca como un archivo local normal. Dirija la conexión a la copia sincronizada.

¿El plan gratuito realmente cubre esto?

Sí. Gratis es un plan que usted conserva, no una prueba que caduca. Vea exactamente lo que incluye en el página de precios.

¿La hoja se actualiza automáticamente?

Haz clic en Ejecutar consulta de nuevo cuando quieras ver las filas más recientes. Para que la hoja se actualice automáticamente según un horario, configura una automatización en el portal de Flujos de consulta (Flujos → Automatización). Esta función está disponible en todos los planes.

¿Sigues atascado? Abrir Ayuda En Query Streams, indíquenos en qué paso se encuentra y qué observa. Le ayudaremos a conectarse.
Query Streams también conecta los mismos datos aExcelClaude, Cursor y ChatGPTuna API RESTy más

Cada guía para SQLite

¿No es exactamente lo que buscas?

  • ¿Tienes una carpeta de archivos SQLite en lugar de uno? SQLite Folder combina las tablas que comparten un nombre en una sola tabla y etiqueta cada fila con el archivo del que proviene → SQLite Folder

Setup trouble?

  • Agent says the file or folder does not exist, or access is denied? Mapped drives, network shares, OneDrive and Linux home folders each need one fix → Where the Agent can read files from
  • Agent shows Offline, or Test connection and Browse are greyed out? Check that the Agent is online → Is the Agent online?
Actualizado el octubre 17, 2026

Funciona con BetterDocs