Meta tags:
description= Lightweight WASM Postgres;
Headings (most frequently used words):
upgrade, upgrading, between, minor, versions, about, docs, extensions, reference, path, using, pg_dump, to, further, reading, framework, hooks, pglite, tools,
Text of the page (most frequently used words):
#pglite (27), #version (26), the (15), project (13), install (11), electric (10), using (10), your (9), pg03 (9), await (8), also (8), upgrade (7), sql (7), npm (7), minor (7), previous (6), example (6), const (6), from (5), that (5), you (4), can (4), for (4), was (4), same (4), newer (4), bash (4), extensions (3), page (3), support (3), linearlite (3), examples (3), query (3), create (3), instance (3), import (3), path (3), and (2), catalog (2), next (2), locale (2), see (2), code (2), migratemodal (2), tsx (2), github (2), this (2), package (2), nextversion (2), rows (2), log (2), console (2), select (2), string (2), search_path (2), exec (2), dumpresult (2), pglite04 (2), with (2), pgcurr (2), pgdump (2), dumpdir (2), currentversion (2), current (2), dump (2), database (2), then (2), use (2), bun (2), yarn (2), pnpm (2), pg_dump (2), upgrading (2), between (2), versions (2), sync (2), repl (2), docs (2), about (2), navigation (2), dual, licensed, under, postgresql, license, apache, pager, full, relevant, folder, https, com, blob, tudor, upgradepathpglite, src, components, branch, further, reading, now, remove, set, public, adapt, needs, text, loaddatadir, none, dumpdatadir, add, into, new, unlike, patch, upgrades, might, introduce, breaking, changes, here, how, debugging, benchmarks, reference, extension, development, prepopulated, tools, socket, postgres, orms, builders, component, multi, tab, worker, bundler, vue, react, framework, hooks, filesystems, live, queries, api, getting, started, videos, what, sidebar, return, top, menu, home, main, search, skip, content,
Text of the page (random words):
upgrading between minor versions pglite skip to content search k main navigation home about docs repl electric github npm menu return to top sidebar navigation about what is pglite videos docs getting started pglite api live queries filesystems framework hooks react vue bundler support multi tab worker repl component orms query builders sync using postgres sync pglite socket pglite tools package pgdump prepopulated fs locale support upgrade path extensions extensions catalog extension development reference examples benchmarks debugging on this page upgrading between minor versions unlike patch version minor version upgrades might introduce breaking changes here is how you can upgrade upgrade path the upgrade path is to use pg_dump to create a database dump from the previous version of pglite and then import into a new instance using pg_dump to upgrade npm pnpm yarn bun bash in a project that is using a previous minor pglite version also install the newer version for example if your project was using v0 3 x also install version 0 4 x in the same project npm install pglite 04 npm electric sql pglite 0 4 0 bash in a project that is using a previous minor pglite version also install the newer version for example if your project was using v0 3 x also install version 0 4 x in the same project pnpm install pglite 04 npm electric sql pglite 0 4 0 bash in a project that is using a previous minor pglite version also install the newer version for example if your project was using v0 3 x also install version 0 4 x in the same project yarn add pglite 04 npm electric sql pglite 0 4 0 bash in a project that is using a previous minor pglite version also install the newer version for example if your project was using v0 3 x also install version 0 4 x in the same project bun install pglite 04 npm electric sql pglite 0 4 0 ts in your upgrade code you can then use your current pglite version to dump the database import pglite from electric sql pglite current version import pglite as pglite04 from pglite 04 next version pg03 is your pglite instance with version 0 3 x const currentversion await pg03 query version string select version console log currentversion rows 0 version const dumpdir await pg03 dumpdatadir none const pgcurr await pglite create loaddatadir dumpdir const dumpresult await pgdump pg03 pgcurr pg03 is pglite instance with version 0 3 x const pg03 await pglite04 create pg03 exec await dumpresult text adapt the search_path to your needs await pg03 exec set search_path public const nextversion await pg03 query version string select version console log nextversion rows 0 version that s it now you can remove the pglite v0 3 x package from your project further reading you can see a full upgrade example in electric sql s linearlite example from 0 2 x to 0 3 x on this branch the relevant code is in examples linearlite folder see migratemodal tsx https github com electric sql electric blob tudor upgradepathpglite examples linearlite src components migratemodal tsx pager previous page locale support next page extensions catalog dual licensed under apache 2 0 and the postgresql license electric
|