Welcome Guest, Not a member yet? Register   Sign In
MySQL foreign key Value insert
#1
Exclamation 
(This post was last modified: 12-10-2014, 10:15 AM by rushdi1987.)

I made two tables

Table Name                        Column Name

debit ->   id (primary key), accountname , vid (foreign key reference to  voucher.id)
voucher -> id (primary key), voucher_no, 


I want to add voucher id no as the vid field.  How do I do that with codeigniter ??? Do i need to use LAST_INSERT_QUERY(),  custom fucntion? Please help me.

Exclamation
Reply


Messages In This Thread
MySQL foreign key Value insert - by rushdi1987 - 12-09-2014, 02:10 PM
RE: MySQL foreign key Value insert - by _this - 12-10-2014, 04:57 AM
RE: MySQL foreign key Value insert - by pravins - 12-10-2014, 05:04 AM



Theme © iAndrew 2016 - Forum software by © MyBB