473,385 Members | 2,162 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,385 software developers and data experts.

storing exploded values into separate db fields

hi,
I ve made a form in php. In that i ve asked the user to fill in the skill sets separated by comma. for eg. key skills: C, C++, Java.
Now when the user enters the data here i want to store that data in database. Ive stored that data in a array variable using the explode function. Here is a sample of code that i am using. I wanted to know how can i store this kind of data in database so that the data corresponds to a particular users profile.
Im not able to store it in database.
Expand|Select|Wrap|Line Numbers
  1. $skills = "C, C++, Java, PHP";   
  2. $arrSkills = explode(",",$skills);      
  3. foreach($arrSkills as $v){   
  4. echo trim($v);   
  5. }  
  6.  
Its printing the names but how to store in database. Plz help me out.
Mar 3 '08 #1
1 1678
ronverdonk
4,258 Expert 4TB
Do you want to store each skill in a separate db field or just the entire string. If the former, do you then have separate db fields for each skill? Show your MySQL data (table info).

Ronald
Mar 3 '08 #2

Sign in to post your reply or Sign up for a free account.

Similar topics

3
by: Murphy | last post by:
I am creating my first mySQL database to store genealogy information and would like fields for date of birth and date of death. Unfortunately some older records are quite vague with only the year...
2
by: hendry.johan | last post by:
Hi, I'm currently developing an HR system which involves storing a lot of configurations per module, such as payroll module, absence/shift module, training module, etc. total: around 100...
14
by: John Welch | last post by:
Hi all. I'm creating a FE/BE database that will be used by about 6 users. As usual, I have several fields, such as "OrganizationTypeID" that will get values (via combo boxes in forms) from separate...
6
by: (PeteCresswell) | last post by:
User wants to go this route instead of storing pointers in the DB and the documents outside. Only time I tried it was with only MS Word docs - and that was a loooong time ago - and it seemed to...
10
by: drago | last post by:
Hello guys again! Back with invoice problems. Just want to know how to store data in the main database in different tables and fields using a form. I have a datasheet view of a form where i have to...
0
by: taylorcarr | last post by:
A Canon printer is a smart device known for being advanced, efficient, and reliable. It is designed for home, office, and hybrid workspace use and can also be used for a variety of purposes. However,...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.