Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9015677
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 16, 20262026-06-16T03:48:35+00:00 2026-06-16T03:48:35+00:00

I am doing queries over multiple databases in SQLite , and I’m having trouble

  • 0

I am doing queries over multiple databases in SQLite, and I’m having trouble using a .* in my queries. I have successfully used the ATTACH function to reference both databases:

dbOne.execute("ATTACH DATABASE 'dbOne.sql' as db1");
dbOne.execute("ATTACH DATABASE 'dbTwo.sql' as db2");

This query here gives me a syntax error (syntax error near *):

dbOne.execute("SELECT db2.myTable.* FROM db2.myTable");

Can I do db2.myTable.*? Or do I have to select each individual column one at a time?

SELECT db2.myTable.columnA, db2.myTable.columnB, db2.myTable.columnC, etc.

Thanks!

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-16T03:48:37+00:00Added an answer on June 16, 2026 at 3:48 am

    In case you have not solved this already, this will work:

    a) dbOne.execute("SELECT * FROM db2.myTable");

    b) dbOne.execute("SELECT abc.* FROM db2.myTable abc");

    Also, you don’t have to specify the database name when the tablename is unique across all attached databases.

    b) is commonly used when you select or join multiple tables, e.g.

    SELECT abc.*, xyz.* FROM db2.myTable abc, db1.myOtherTable xyz

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have a somewhat complex query with multiple (nested) sub-queries, which I want to
I've just switched over to using ADODB with MySQL and PHP... I'm having troubles
I'm having some huge performance issues with facet queries. I have an index of
I am doing lots of queries to my database with NSURLConnection Asynchronously, I have
I'm working on a database program and I noticed that when I'm doing queries
I am doing some pre-processing on my database. Basically two queries, one is INSERT
Doing an ajax get request works as expected using the following code: $.ajax({ type:
Doing some jquery animation. I have certain divs set up with an attribute of
Some folks using our software have gone ahead and done a database server move
I have a .SQL file containing a large number of queries. They are being

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.