Virtual database table creation

new BookmarkLockedFalling
sundale
New Member
*

sundale Avatar

Posts: 34

Post by sundale on Jan 3, 2010 12:44:46 GMT -5

I haven't learn SQL yet, just understand basic things.
but I need to write SQLite code for quick solution. Please help.


I have two table as bellow:

tablea code char(4), desc char(50), unit char(4)
tableb code char(4), amount char(6)

How do write sql statement to generate tablec according to tableb?

tablec code char(4), desc char(50), unit char(4), amount char(6)

Q1: if the two tables are in the same database file, how to create tablec?
Q2: if the two tables are in different database files, how to create tablec?

-sundale
i7Q720/win7/ RB v1.0.1 Build 2.44
StefanPendl
Global Moderator
*****

StefanPendl Avatar

Run for BASIC ...
Posts: 945

[b]Stefan[/b] - [a href=http://stefanpendl.runbasichosting.com/]Homepage[/a][br][br][b]Please give credit if you use code I post, no need to ask for permission.[/b][br][br]Run BASIC 1.01, Fire-/Waterfox (IE11, Edge), Windows 10 Professional x64, Intel Core i7-4710MQ 2.5GHz, 16GB RAM