Hi guys i have a question need to ask. I create an application for filling up information. After filling if he want to update when press update and fill up active = from yes to No then it will remove the table 1 to table 2 by using the sql INSERT INTO.

So will it work if i do like that?

I'm a newbie in vb6 need advise.

Thank you and please help me

as an example...

strSQL = "SELECT Table2.iID, Table2.iNum INTO Table3 FROM Table2"

Good Luck

as an example...

strSQL = "SELECT Table2.iID, Table2.iNum INTO Table3 FROM Table2"

Good Luck

So the code mean i can just move the data no need to write if else statement then only the sql statement ah ??

The update form will automatic get the data from sql table 1 & 2 so what code i need to write. Please advise me

Thank you

Yes, you will need an if statement.

The code I gave you is for creating a new table from an old table, as in all the records from table1 will be inserted into table2 of which table2 is created. The result is that you will have two tables with the same information. And once again. I ask why?


Good Luck

Yes, you will need an if statement.

The code I gave you is for creating a new table from an old table, as in all the records from table1 will be inserted into table2 of which table2 is created. The result is that you will have two tables with the same information. And once again. I ask why?


Good Luck

Hi,

the two table most of the detail same but one table contain new user info that badge id is active and other table contain old user that badge id is non active.

FYI: One badge id will have lot of people using it before. It also can be recycle to use . So that why i need to do two table to divided the active user which using the same badge id and the one who have the same badge id but no active user. so the primary key in this two table is the badge id and foreign key the employee name


That why i need to ask you to confirm this will work or not.


I have one main page, add detail page & update page. All of them are SDI. The main page just a badge id text field when user key in badge id then the info will show on the data grid. the data grid will get info from two table using the sql method INNER JOIN.

2. then the add page. The add page is add info into two table depend the badge id is active or not. This i need to use the method you teach me to do.

3 the update page will update the info that have in table 1 & 2. When user first type badge id, the textfield emp id will auto out the possible emp id, then the txtname also the same. When the txtname press enter it will show out the rest of the information
Then updated it but if active to not active it will change frm table 1 to table 2.

See my post in your other thread...


Good Luck

See my post in your other thread...


Good Luck

which thread?? can explain it here

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.