One Namespace, One Workgroup: Datashare Is Redshift Serverless's Back Door

Want a second Redshift Serverless workgroup for isolated compute? We can't attach it to the same namespace—the relationship is 1:1. But there's a back door: create a new namespace/workgroup and use Datashare to access the data from the original namespace. Our new workgroup gets its own compute capacity while still being able to query and JOIN the shared tables.

One Namespace, One Workgroup: Datashare Is Redshift Serverless's Back Door

One Namespace, One Workgroup: Datashare Is Redshift Serverless's Back Door

Before We Start: What This Post Is (and Very Much Isn't)

If you came here expecting a complete Amazon Redshift A-to-Z tutorial, I have bad news: your coffee can cool down now. ☕

This post is not a Redshift A-to-Z. This post deliberately focuses on one specific architectural problem, not a Redshift A-to-Z.

This post has exactly one job: to explain a very specific, very common moment of confusion in Amazon Redshift Serverless:

“We already have a Redshift Serverless workgroup attached to a namespace. We want another isolated workgroup with its own compute capacity, but we still want that new workload to query and JOIN the existing data. Can we attach the new workgroup to the same namespace?”

The short answer is:

No. A Redshift Serverless namespace and workgroup have a 1:1 relationship.

But there is a very useful second question:

“If we cannot attach two workgroups to one namespace, how can the second workgroup access the first namespace's data without copying everything?”

That's where Amazon Redshift Datashare enters the story.

That's the whole post. We'll cover:

  1. What a namespace is.
  2. What a workgroup is.
  3. Why the namespace/workgroup relationship matters.
  4. Why we cannot attach a second workgroup to the existing namespace.
  5. Why Datashare exists, and what problem it's actually solving.
  6. How a producer namespace and consumer namespace work.
  7. How the consumer workgroup can query and JOIN shared tables.
  8. A practical architecture for isolating compute while reusing existing data.
  9. The important caveats and design considerations.

The goal is not to cover every Redshift feature. The goal is to make this one architectural puzzle crystal clear.


1. First, Meet the Two Characters: Namespace and Workgroup

Before discussing Datashare, we need to establish one mental model.

In Redshift Serverless, think of a namespace as the place where our data and database resources live, while a workgroup is the compute environment used to process queries against that data.

A simplified picture looks like this:

A namespace and workgroup as a locked 1:1 pair Two boxes side by side. The left box, Namespace, lists Database, Schemas, Tables, Views, Users/Roles/Data, and Persistent storage. The right box, Workgroup, lists Compute, RPU capacity, Endpoint, and Networking configuration. A line labeled 1 to 1 connects them in the middle. NAMESPACE Database Schemas Tables Views Users / Roles / Data Persistent storage 1 : 1 WORKGROUP Compute RPU capacity Endpoint Networking configuration
Figure 1: One namespace, one workgroup — a locked 1:1 pair.

This distinction is the foundation for everything that follows.


What Is a Namespace?

A namespace is the collection of database objects and users. It owns:

  • Our databases, schemas, and tables (the actual data)
  • Users and permissions
  • Encryption keys (KMS settings)
  • Snapshots and backups
  • Admin credentials

In short: the namespace is our data estate. It answers the question "what data exists, and who's allowed to see it?"

In other words: We can think of it as:

“This is where our Redshift data lives.”


What Is a Workgroup?

A workgroup is where the compute side of Redshift Serverless comes into play. It's the collection of database objects and users. It owns:

  • RPUs (Redshift Processing Units) — the actual horsepower that runs our queries
  • Network configuration — VPC, subnets, security groups
  • The query endpoint our applications and BI tools connect to
  • Usage limits and query queue configuration

In short: The workgroup is simply our compute unit. It defines our processing power and the network path to access it.

That's it. That's the whole primer. Now let's get to the actual drama.


2. The Plot Twist: Namespace and Workgroup Are 1:1

Here's the plot twist that catches almost everyone off guard the first time they try to scale out:

In Redshift Serverless, a namespace can be attached to exactly one workgroup, and a workgroup can be attached to exactly one namespace. Period.

It's a strictly monogamous, one-to-one relationship. Not one-to-many. Not many-to-many. One. To. One.

So here's the scenario that trips people up:

We already have a namespace — let's call it analytics-ns — happily paired with a workgroup called analytics-wg. Our analytics team has been querying away for months. Life is good.

Then a new team shows up — say, the fraud detection team. They need their own compute so their heavy queries don't compete with (or accidentally throttle) the analytics team's dashboards. Totally reasonable ask. So we think:

"Easy — we'll just spin up a new workgroup, fraud-wg, and point it at the existing analytics-ns namespace. Same data, dedicated compute. Done!"

And Redshift Serverless says: absolutely not.

A namespace can only be paired with one workgroup at a time Namespace analytics-ns is connected by a solid line to analytics-wg, marked as already married. A second, dashed line from analytics-ns to a hypothetical fraud-wg is marked blocked, since a namespace can only have one partner. analytics-ns analytics-wg fraud-wg already married blocked one namespace, one partner
Figure 2: One namespace, one partner — analytics-ns is already paired; fraud-wg can't attach to it too.

We cannot attach a second workgroup to a namespace that already has one. If we want fraud-wg to exist as an isolated workgroup, it needs its own namespace — let's call it fraud-ns.


So Why Does AWS Enforce This?

AWS's own documentation doesn't spell out an explicit reason for why the pairing has to be strictly 1:1 — it simply states that namespaces and workgroups exist to let us isolate workloads and manage storage and compute separately. AWS doesn't publish a "here's exactly why it's one-to-one" explanation anywhere.

That said, the design makes a lot of sense once we think through what a workgroup and namespace together represent.

A. Compute isolation stays clean

A workgroup represents a compute environment with its own capacity and workload characteristics.

If multiple independent workgroups could freely attach to the same namespace, the relationship between data ownership and compute consumption would become considerably more complicated.

With 1:1, the mental model stays wonderfully simple:

The 1:1 chain from namespace to workgroup to compute Namespace A points down to Workgroup A, which points down to its compute. A single straight line, no branching. Namespace A Workgroup A Its compute
Figure 3: The 1:1 relationship flows straight through — one namespace, one workgroup, one compute environment.

Want another isolated compute environment?

We get another namespace/workgroup pair.


B. Cost and capacity stay easier to reason about

Redshift Serverless compute is expressed in RPUs, and usage limits can be configured for a workgroup.

Keeping the workgroup association unambiguous makes it much easier to answer questions like:

“Which workload is consuming this compute?”

and:

“Which workgroup should we scale or place a usage limit on?”

Now imagine several independent workgroups hanging off the same namespace.

Suddenly, the architecture starts looking less like a clean apartment building and more like a shared utility cupboard where everyone has plugged in their own extension cord.

One namespace cannot cleanly fan out to three workgroups A box labeled Same Namespace connects down to three workgroup boxes, WG-A at 24 RPU, WG-B at 32 RPU, and WG-C at 16 RPU, illustrating the ambiguity of one namespace serving multiple workgroups. Same Namespace WG-A 24 RPU WG-B 32 RPU WG-C 16 RPU
Figure 4: If one namespace fanned out to three workgroups, whose usage limit applies? The model stays ambiguous.

The 1:1 model avoids that ambiguity.


C. Network configuration belongs to the workgroup

Workgroups carry compute-side configuration such as networking settings.

That separation is useful because the compute environment can have its own connectivity requirements without turning the namespace itself into a container for multiple competing compute/network configurations.

Again, the 1:1 relationship keeps the architecture easier to reason about:

A workgroup owns compute, endpoint, and network configuration Namespace points down to Workgroup. Workgroup branches into three items it owns: Compute, Endpoint, and Network configuration. Namespace Workgroup Compute Endpoint Network configuration
Figure 5: A workgroup owns its own compute, endpoint, and network configuration — separate from the namespace.

D. The model gives us a clean ownership boundary

Perhaps the most useful way to think about the design is this:

  • The namespace represents the data/database side
  • The workgroup represents the compute side

AWS gives us a 1:1 relationship between them.

That makes the default architecture beautifully predictable:

The default, predictable 1:1 shape Namespace, holding data and database, connects 1 to 1 down to Workgroup, which holds compute and endpoint. Namespace Data / Database 1 : 1 Workgroup Compute / Endpoint
Figure 6: The default, predictable shape — one namespace, one workgroup, connected 1:1.

But this creates an interesting problem.

What if we want another isolated compute environment while still working with the same data?

The obvious thing we'd like to do is:

The naive attempt to fan a namespace out to two workgroups Namespace points down to two workgroups, WG-A at 24 RPU and WG-B at 32 RPU, marked not supported, since Redshift Serverless does not allow this. Namespace not supported WG-A 24 RPU WG-B 32 RPU
Figure 7: The naive fix doesn't work — a namespace can't fan out to two workgroups.

Unfortunately, that's not how Redshift Serverless is designed.

The answer isn't to fight the 1:1 model.

The answer is to work with it:

  • Create another namespace
  • Create another workgroup

And then ask the really interesting question:

How do we let this new workgroup use the data that already lives in the original namespace — without simply copying the whole dataset?

That's where Datashare walks into the room.


3. If Namespaces Can't Be Shared, How Does Anyone Query Across Them?

This is where most people start Googling. Or, let's be honest, asking an LLM to save them from reading the docs.

The fraud team's new fraud-ns + fraud-wg pair is a totally empty house. No tables, no data, nothing. But the fraud team's queries absolutely need to JOIN against tables that live in analytics-ns — things like the master customers table or the transactions table.

Duplicating that data into fraud-ns is the obvious hacky workaround, and it's a bad one:

  • Now we have two copies of the truth, which will drift out of sync
  • We've doubled our storage costs
  • Every schema change now needs to be replicated manually or via some fragile pipeline
  • Our security team now has two places to audit permissions on the same sensitive data

This is exactly the gap that Datashare was built to close.


Enter Datashare: Finally, a Way Out of This 1:1 Nightmare

Redshift Datashare lets one namespace (the producer) share live, read-only access to specific databases, schemas, or tables with another namespace (the consumer) — without copying a single byte of data.

Crucially, here's the part that makes it click:

When the consumer namespace queries shared data, it does so using its own workgroup's compute capacity (RPUs) — not the producer's.

So the fraud team's fraud-wg uses its own dedicated RPUs to scan, filter, and JOIN against data that physically still lives in analytics-ns. The analytics team's compute is never touched. No contention, no duplication, no drift.

The datashare pattern: producer and consumer namespace/workgroup pairs On the left, the producer: analytics-ns, holding customers and transactions data, connected up to its own analytics-wg compute. On the right, the consumer: fraud-ns, which sees the shared data but owns nothing itself, connected up to its own fraud-wg compute, which pays for and runs the JOIN. A horizontal arrow labeled Datashare, read-only, no copy, connects the producer namespace to the consumer namespace. PRODUCER CONSUMER analytics-ns owns the data customers · transactions fraud-ns sees the data, owns nothing DATASHARE (read-only, no copy) analytics-wg its own RPUs, untouched by fraud's queries fraud-wg its own RPUs runs the JOIN — pays its own compute bill
Figure 8: The datashare pattern in practice — analytics-ns/analytics-wg (producer) and fraud-ns/fraud-wg (consumer), connected read-only, no copy.

This is genuinely the elegant part of the design: Datashare decouples "who owns the data" from "who pays for the compute to query it." The producer keeps full ownership and governance. The consumer gets to run its own workload, on its own dime, on its own schedule — against live data, not a stale copy.


4. The Back Door: Sharing Data Without Sharing the Workgroup

Now let's stop talking about architecture diagrams and actually build the thing.

Our scenario is simple.

We already have:

What we already have: analytics-ns through analytics-wg to its tables analytics-ns points down to analytics-wg, running 24 RPU, which points down to the customers and transactions tables. analytics-ns analytics-wg 24 RPU customers transactions
Figure 9: What we already have — analytics-ns, its workgroup, and the tables it owns.

And we want a completely separate compute environment for our fraud detection workload:

What we want: a new fraud-ns paired with its own fraud-wg fraud-ns points down to fraud-wg, running 32 RPU. fraud-ns fraud-wg 32 RPU
Figure 10: What we want — a brand-new fraud-ns / fraud-wg pair, fully isolated.

The catch?

Our fraud workload still needs to read some of the data owned by analytics-ns.

We can't attach fraud-wg to analytics-ns.

So instead, we create a second namespace/workgroup pair and use Datashare as the bridge.

Here's what we're about to build:

The full producer/consumer datashare we're about to build A producer box containing analytics-ns, its workgroup analytics-wg at 24 RPU, and the shared tables public.customers and public.transactions. A Datashare arrow points down to a consumer box containing fraud-ns, its workgroup fraud-wg at 32 RPU, and its own fraud_detection.suspicious_activity table. PRODUCER analytics-ns analytics-wg · 24 RPU public.customers public.transactions Datashare CONSUMER fraud-ns fraud-wg · 32 RPU fraud_detection.suspicious_activity + shared: customers, transactions
Figure 11: What we're about to build — a producer/consumer datashare between analytics-ns and fraud-ns.

Let's open the back door.

Step 1 — Create the Datashare

First, we connect to the producer namespace, analytics-ns, through analytics-wg.

We create the datashare:

CREATE DATASHARE fraud_share;

Next, we decide exactly what our fraud workload needs to access.

In our example, that's just two tables:

ALTER DATASHARE fraud_share ADD SCHEMA public;

ALTER DATASHARE fraud_share ADD TABLE public.customers;

ALTER DATASHARE fraud_share ADD TABLE public.transactions;

That's an important detail.

We're not throwing open the entire namespace and shouting, “Come on in, everybody!”

We're explicitly choosing which objects cross the boundary.

Only two tables in analytics-ns are actually shared analytics-ns branches into five objects. public.customers and public.transactions are marked shared. internal.audit_log, staging.raw_events, and admin.etl_control are marked not shared. analytics-ns SHARED public.customers public.transactions NOT SHARED internal.audit_log staging.raw_events admin.etl_control
Figure 12: The datashare only exposes what's explicitly added — everything else in analytics-ns stays private.

The producer remains the owner of the original data.

The datashare simply defines what we're willing to expose.


Step 2 — Give the Consumer an Invitation

Creating the datashare isn't enough. We also need to tell Redshift which namespace is allowed to consume it.

Still on analytics-ns:

GRANT USAGE ON DATASHARE fraud_share
TO NAMESPACE 'fraud-ns-namespace-id';

Think of this as the guest-list check.

Granting usage on the datashare to the consumer namespace analytics-ns points down to fraud_share, which points down to fraud-ns, labeled fraud-ns is allowed in. analytics-ns fraud_share "fraud-ns is allowed in" fraud-ns
Figure 13: Granting usage on the datashare is the guest-list check — only fraud-ns gets in.

We're not giving the entire Redshift universe access to the share. We're explicitly granting our consumer namespace access.


Step 3 — The Consumer Accepts the Share

Now we switch sides.

We connect to the consumer namespace, fraud-ns, through its own workgroup, fraud-wg.

We create a database from the datashare:

CREATE DATABASE analytics_shared
FROM DATASHARE fraud_share
OF NAMESPACE 'analytics-ns-namespace-id';

And just like that, the shared data becomes available from the consumer side.

Conceptually, fraud-ns now has something like:

fraud-ns after accepting the datashare fraud-ns branches into its own native table, suspicious_activity, and a shared group giving access to public.customers and public.transactions via the datashare. fraud-ns OWN TABLE suspicious_activity SHARED VIA DATASHARE public.customers public.transactions
Figure 14: From fraud-ns, the native suspicious_activity table sits alongside the shared analytics data.

Notice what happened.

We didn't create another copy of the customers table just so our fraud workload could read it.

We're accessing the data owned by the producer through the share.


Step 4 — Now Let's Do Something Useful With It

This is where the whole architecture starts to pay off.

Suppose our fraud namespace has its own table:

fraud_detection.suspicious_activity

It contains:

transaction_id
customer_id
flag_reason

Meanwhile, the producer owns:

public.customers

with:

customer_id
customer_name
risk_score

Our fraud workload can now combine the two:

SELECT
    f.transaction_id,
    f.flag_reason,
    c.customer_name,
    c.risk_score
FROM fraud_detection.suspicious_activity f
JOIN analytics_shared.public.customers c
    ON f.customer_id = c.customer_id;

And this is the moment to pause and appreciate what's happening.

One side of the JOIN is native data in fraud-ns.

The other side is shared data owned by analytics-ns.

Yet the query is submitted through:

fraud-wg

and uses the consumer workgroup's compute environment.

The producer doesn't need to become the fraud team's compute engine.

The fraud workload doesn't need a second copy of the producer's entire dataset.

We have effectively achieved:

Data ownership and compute ownership, joined only by the datashare On the left, data ownership: analytics-ns down to the customers and transactions tables. On the right, compute ownership: fraud-ns down to fraud-wg at 32 RPU. Both converge through the datashare into a single query and JOIN. DATA OWNERSHIP COMPUTE OWNERSHIP analytics-ns customers table transactions table fraud-ns fraud-wg 32 RPU Datashare Query + JOIN
Figure 15: Data ownership stays with analytics-ns; compute ownership stays with fraud-wg — Datashare is the only bridge.

That's the back door.

We're respecting Redshift Serverless's 1:1 namespace/workgroup model instead of trying to work around it.

The second workgroup gets its own compute environment.

The producer keeps ownership of the original data.

And Datashare provides the controlled path between them.


5. What If We Decide to Move the Workload Later?

So far, we have solved the runtime isolation problem:

Namespace and workgroup pairs providing isolated compute environments Two rows. Top row: existing_namespace box connected by an arrow to existing_workgroup at 24 RPU. Bottom row: new_app_namespace box connected by an arrow to new_app_workgroup at 32 RPU. Left labels read EXISTING and NEW / ISOLATED. EXISTING existing_namespace existing_workgroup 24 RPU NEW / ISOLATED new_app_namespace new_app_workgroup 32 RPU
Figure 16: Two isolated namespace/workgroup pairs — each with its own dedicated compute.

Datashare lets the second environment query data owned by the first.

But there is another very practical scenario worth covering.

What happens if, six months from now, we look at the workload and conclude:

“The existing workgroup has enough capacity. We don't need a dedicated workgroup for this application anymore.”

For example, imagine that the the application application starts like this:

The initial dedicated application namespace and workgroup new_app namespace points down to new_app workgroup, which points down to 8 RPU. Labelled INITIAL DEDICATED ENVIRONMENT at the top. INITIAL DEDICATED ENVIRONMENT new_app namespace new_app workgroup 8 RPU
Figure 17: The initial dedicated application namespace and workgroup.

Later, after measuring the workload, we decide that the existing environment can comfortably handle it:

existing_namespace namespace
        │
        ▼
existing_namespace workgroup
        │
        ▼
       32 RPU

There is an important catch.

We cannot simply point existing_namespace's workgroup at the new_app namespace.

The 1:1 relationship still applies.

So the question changes from:

“Can we move the workgroup?”

to:

“How do we move the data from the new_app namespace into the existing_namespace namespace?”

This is where Redshift gives us several options.


Option 1 — Datashare: Access the Data Without Moving It

The first option is Datashare.

We have already seen this pattern:

Datashare providing controlled access from the existing namespace to data owned by the new application namespace On the left, new_app namespace box labelled DATA OWNER. On the right, existing_namespace box labelled CONSUMER. A horizontal Datashare arrow points from left to right. DATA OWNER CONSUMER new_app namespace application data existing_namespace namespace existing workloads Datashare
Figure 19: Datashare providing controlled access from the existing namespace to data owned by the new application namespace.

This is particularly useful if the immediate goal is to test the the application workload on the existing workgroup before physically moving the data.

The existing_namespace workgroup can query the shared the application data using its own compute.

That gives us a useful validation path:

Datashare as a validation bridge before committing to consolidation new_app namespace points down via a Datashare arrow to existing_namespace, which points down to existing_namespace workgroup, which points down to Run the application queries. new_app Datashare existing_namespace existing workgroup Run the application queries
Figure 18: Datashare as a validation bridge — test the workload on the existing workgroup before physically moving any data.

But Datashare does not migrate the data

This distinction is important.

Datashare means:

“Keep the data where it is and let another namespace query it.”

It does not mean:

“Move the data into the other namespace.”

The source new_app namespace continues to own the underlying data.

That means Datashare is useful for:

  • Workload validation
  • Performance testing
  • Temporary cross-namespace access
  • Avoiding an immediate data copy

But if the final goal is:

new_app namespace
        │
        ▼
      gone

then Datashare alone is not enough.

The source namespace still needs to exist while it owns the shared data.

AWS documents Serverless data sharing here:

Amazon Redshift Serverless data sharing

There is also an important cost distinction: for data sharing, the consumer pays the compute required to query the shared data, while the producer continues to bear the underlying storage cost. For same-Region sharing, AWS does not charge cross-Region data-transfer fees because there is no cross-Region transfer. citeturn0search17

So Datashare can be an excellent bridge, but it should not be confused with a migration mechanism.


Option 2 — UNLOAD → S3 → COPY: Move the Data

If the goal is to actually move the the application data into the existing existing_namespace namespace, the most straightforward approach is:

UNLOAD to S3 then COPY into the target namespace new_app points down via UNLOAD to Amazon S3, which points down via COPY to existing_namespace. new_app UNLOAD Amazon S3 COPY existing_namespace
Figure 20: The UNLOAD → S3 → COPY migration path — data physically moves from the source namespace to the target.

This is the approach we would generally recommend for the consolidation scenario.

Step 1 — UNLOAD from the source namespace

From the new_app environment, we export the required data to Amazon S3.

For example:

UNLOAD ('SELECT * FROM new_app_schema.customers')
TO 's3://<migration-bucket>/rc-rosters/customers/'
FORMAT AS PARQUET;

We can control what gets exported using the SELECT statement.

That means we can migrate:

  • Selected tables
  • Selected columns
  • Filtered data
  • Transformed data, if required

Amazon Redshift writes the query results to one or more files in S3 and is designed to support parallel reloading of those files. citeturn0search5turn0search11

AWS reference:

UNLOAD — Amazon Redshift SQL Reference


Step 2 — Create the target tables

Before loading the data, we create the required schema and table definitions in existing_namespace.

For example:

CREATE SCHEMA new_app_schema;

CREATE TABLE new_app_schema.customers
(
    customer_id   BIGINT,
    customer_name VARCHAR(200),
    risk_score    INTEGER
);

The target table can be designed to match the application's requirements rather than blindly reproducing every object from the source namespace.


Step 3 — COPY the data into the target namespace

Once the files are in S3, we load them into existing_namespace:

COPY new_app_schema.customers
FROM 's3://<migration-bucket>/rc-rosters/customers/'
FORMAT AS PARQUET;

AWS reference:

COPY — Amazon Redshift SQL Reference

The resulting architecture becomes:

┌─────────────────────────────────────┐
│        existing_namespace           │
│                                     │
│  Existing tables                    │
│                                     │
│  new_app_schema                     │
│      ├── customers                  │
│      ├── rosters                    │
│      └── transactions               │
└──────────────────┬──────────────────┘
                   │
                   ▼
        existing_namespace workgroup
                 32 RPU

Now the the application workload is using the same namespace and workgroup as the existing applications.

The biggest advantage is that this is an actual data migration, not just data access.

After successful validation:

new_app data
      │
      │ UNLOAD
      ▼
     S3
      │
      │ COPY
      ▼
existing_namespace data

The source namespace can eventually be decommissioned.

It also gives us a controlled migration process:

Export
   ↓
Validate files
   ↓
Create target tables
   ↓
Load
   ↓
Validate row counts
   ↓
Validate application queries
   ↓
Cut over application
   ↓
Decommission source

The large-data-volume caveat

This approach is straightforward, but data volume matters.

For example:

500 GB
  │
  ▼
UNLOAD → S3 → COPY

is very different operationally from:

20 TB
  │
  ▼
UNLOAD → S3 → COPY

Large-volume migrations require planning around:

  • UNLOAD duration
  • COPY duration
  • S3 storage during migration
  • S3 request activity
  • Source and target compute consumption
  • Impact on existing workloads
  • Migration window
  • Data changing while the migration is in progress
  • Validation
  • Final cutover
  • Whether multiple migration passes are required

The issue is not that Redshift cannot move large datasets using UNLOAD and COPY.

The issue is that large datasets turn a simple copy into a migration project.

For very large the application datasets, we should therefore assess whether the migration window, source-change rate, target workload impact, and validation requirements make this approach practical.

Where network isolation is important, Redshift supports VPC endpoints and enhanced VPC routing so COPY and UNLOAD traffic between a workgroup and S3 can remain within the VPC.

AWS reference:

Controlling database traffic with VPC endpoints


Option 3 — Snapshot / Table Restore

The third option is snapshot/table restore.

Redshift Serverless supports restoring a specific table from a snapshot or recovery point into a target database, schema, and new table name.

Conceptually:

new_app namespace
        │
        │ Snapshot
        ▼
   Recovery point
        │
        │ Restore table
        ▼
existing_namespace namespace

For example, we could restore a source table into the existing namespace rather than restoring an entire database.

AWS documents this capability here:

Restoring a table — Amazon Redshift

The important detail is that table restore is not the same thing as restoring the entire namespace.

AWS states that a specific table can be restored by specifying the source snapshot/recovery point, source database/schema/table, and target database/schema/table. The restored table gets the source table's column and table attributes, but dependencies such as views and permissions are not automatically applied. citeturn0search0

That makes table restore potentially useful for selected tables.

However, there are practical limitations.

For example:

  • Only one table can be restored at a time.
  • Table dependencies need to be considered separately.
  • Views and permissions need to be handled separately.
  • The restored table represents the state captured by the snapshot/recovery point.
  • It does not automatically solve the application cutover problem.

AWS also supports restoring an entire snapshot to a Serverless namespace, but there is a major difference:

Restoring a snapshot to a Serverless namespace replaces the current database with the database in the snapshot.

That is obviously a very different operation from selectively adding the application tables into an already-active existing_namespace namespace. citeturn0search1

For that reason, full namespace snapshot restore is not a good fit for this consolidation scenario.

Recommendation for this option

Snapshot/table restore is a valid Redshift capability, but for our specific scenario it is not the preferred migration approach.

The target namespace already contains existing workloads and data.

For a controlled application-data migration, UNLOAD → S3 → COPY gives us more explicit control over what gets moved, how it gets loaded, and how the cutover is managed.


Comparing the Migration Options

Now the three options can be viewed side by side:

Option What it does Data physically moved? Source namespace still needed? Best use
Datashare Provides live cross-namespace access No Yes Validation, temporary access, workload testing
UNLOAD → S3 → COPY Exports and loads selected data Yes No, after successful migration Recommended for consolidation
Snapshot / Table Restore Restores table data from a snapshot/recovery point Yes No, after successful migration Selected table restoration

The easiest way to remember the difference:

Datashare
─────────
"Let us query the data where it already lives."


UNLOAD → S3 → COPY
──────────────────
"Move the data to the new home."


Snapshot / Table Restore
───────────────────────
"Restore selected data from a point-in-time backup."

Recap: The Two Sentences That Matter

If we remember nothing else from this post, remember these two sentences:

  1. A workgroup and a namespace are locked into a strict 1:1 relationship — if we want a new, isolated workgroup, we need a new, isolated namespace to go with it.
  2. Datashare exists precisely to undo the pain of that isolation — it lets a new namespace query another namespace's tables live, using its own compute, without copying any data.

Namespace and workgroup can only ever be exclusive. But thanks to Datashare, "exclusive" doesn't have to mean "isolated from everyone else's data forever." It just means everyone brings their own compute to the table.

And if the workload eventually needs to move into an existing namespace, we have a second path:

Validate with Datashare
          │
          ▼
If consolidation makes sense
          │
          ▼
UNLOAD → S3 → COPY
          │
          ▼
Move the data
          │
          ▼
Run on the existing workgroup

That is the important distinction:

Datashare is the bridge for accessing data across namespace boundaries. UNLOAD → S3 → COPY is the bridge for actually moving data across those boundaries.

If we remember nothing else from this post, remember these two sentences:

  1. A workgroup and a namespace are locked into a strict 1:1 relationship — if we want a new, isolated workgroup, we need a new, isolated namespace to go with it.
  2. Datashare exists precisely to undo the pain of that isolation — it lets a new namespace query another namespace's tables live, using its own compute, without copying any data.

Namespace and workgroup can only ever be exclusive. But thanks to Datashare, "exclusive" doesn't have to mean "isolated from everyone else's data forever." It just means everyone brings their own compute to the table.


References

  1. Workgroups and namespaces — Amazon Redshift
  2. Data sharing in Amazon Redshift Serverless
  3. UNLOAD — Amazon Redshift SQL Reference
  4. COPY — Amazon Redshift SQL Reference
  5. Restoring a table — Amazon Redshift
  6. Restoring a snapshot — Amazon Redshift
  7. Snapshots and recovery points — Amazon Redshift
  8. Controlling database traffic with VPC endpoints — Amazon Redshift

Comments