|
-
Mar 2nd, 2015, 06:03 AM
#1
Thread Starter
Member
Help in assigning database value to array value
Hello, Code Masters,
Here I am again today going to seek help and guidance from you.
I have here a manually assigned values to arrays 0 - 19
now my question is, how can I assign values to each array coming from the SQL database?
The catch is, it is a different SQL statement (specifically a different where clause) for each array value. For example:
CorrectAnswer(0) = select data where fieldValue = 1
CorrectAnswer(1) = select data where fieldValue = 2
CorrectAnswer(2) = select data where fieldValue = 3
CorrectAnswer(3) = select data where fieldValue = 4
and so on..
Any additional inputs will be greatly appreciated.
I tried by the way the use of data table however I am not sure how to do it because of the condition (different where clause for each array value).
Hoping you are able to get my meaning.
Thank you!
Tags for this Thread
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|