question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Multiple datasources not working

See original GitHub issue

I’m following the documentation to target multiple datasources:

datasource postgres {
  provider = "postgres"
  enabled = env("POSTGRES_URL")
  url = env("POSTGRES_URL") 
}

datasource sqlite {
  provider = "sqlite"
  enabled = env("SQLITE_URL")
  url = env("SQLITE_URL")
}
$ echo $POSTGRES_URL
postgresql://peterp:xxx@localhost:5432/peterp?schema=public

$ prisma2 lift up
Error: Error in lift engine for rpc listMigrations:
  thread 'main' panicked at 'loading the connector failed.: DataModelErrors { code: 1001, errors: ["Expected a boolean value, but failed while parsing \"postgresql://peterp:xxx@localhost:5432/peterp?schema=public\": failed to parse bool.", "Environment variable not found: SQLITE_URL."] }', src/libcore/result.rs:997:5
stack backtrace:

Environment variable not found: SQLITE_URL.

$ export SQLITE_URL=false

$ prisma2 lift up
Error: Error in lift engine for rpc listMigrations:
  thread 'main' panicked at 'loading the connector failed.: DataModelErrors { code: 1001, errors: ["Expected a boolean value, but failed while parsing \"postgresql://peterp:xxx@localhost:5432/peterp?schema=public\": failed to parse bool."] }', src/libcore/result.rs:997:5

Expected a boolean value, but failed while parsing \"postgresql://peterp:xxx@localhost:5432/peterp?schema=public\": failed to parse bool."

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:1
  • Comments:20 (12 by maintainers)

github_iconTop GitHub Comments

4reactions
sameoldmadnesscommented, Jul 29, 2019

I’ll create a PR later today, if it’s ok.

UPD: #285

3reactions
sameoldmadnesscommented, Jul 29, 2019

Multiple datasources are currently not implemented.

Would it make sense to add a note to the docs?

I’ve spent a couple of hours trying to make it work : )

Read more comments on GitHub >

github_iconTop Results From Across the Web

Tests not working for multiple datasource with spring boot ...
I am creating unittesting for spring boot application having multiple datasources. (Configuration is heavily inspired from this answer).
Read more >
Configure and Use Multiple DataSources in Spring Boot
In this tutorial, we'll learn how to configure and use multiple data sources with Spring Boot. To find out how to deal with...
Read more >
Configure Spring boot multiple data source :not working
I have a requirement to configure one DB for Camunda Engine and another for Business entities. ... Camunda related config DB works but...
Read more >
Working with multiple data sources in Spring boot project
Getting a single data source in Spring boot is as simple as defining few properties in config file as :
Read more >
Filter Data Across Multiple Data Sources - Tableau Help
While working with multiple data sources in a workbook, you might want to compare the ... Filtering data across a worksheet's secondary data...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found