Reply
Duplicating SQL values
Old 06-21-2004, 02:11 AM Duplicating SQL values
Registered User

Posts: 1
I would like to copy a value 'userID' to a field in the same database 'pid' automatically when someone registers. I use the second as a lookup field. The userID field is an autoincrement. Can this be done?
mexicomike is offline
Reply With Quote
View Public Profile
 
When You Register, These Ads Go Away!
Old 06-21-2004, 10:37 AM do it in SQL
ibbo's Avatar
Super Spam Talker

Posts: 880
Location: Leeds UK
do go getting in a muddle using PHP when you can simply throw it some sql.

update table set table.pid = table.UserID

can be simply used from your register code.

Ibbo
ibbo is offline
Reply With Quote
View Public Profile Visit ibbo's homepage!
 
Reply     « Reply to Duplicating SQL values
 

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off




   
RSS Feed  Feeds: RSS   JS   XML
RSS Feed  Feeds for this forum: RSS   JS   XML

 


Page generated in 0.11368 seconds with 12 queries