Skip to content

PHP-Sandbox - PHP script help - support array in array #562

Answered by sam8881998
sam8881998 asked this question in Q&A
Discussion options

You must be logged in to vote

Dear Chris,

Thank you so much for your reply.
I tested and if the json file is changed to below, and I need to store the record like:

Table structure: Autonumber (managed by database automatically), Number, Name, Title

I would like to have the below Stored Table Data result:
10001, 50,Name 50, Null
10002, 2,Name 2, manager
10003, 2,Name 2, Student
10004, 1000,Name 1000, department head
10005, 1000,Name 1000, Supervisor

I changed a little bit coding (I was adding the indicator but still not working and below is the latest version) but get two Null records for name 2 and Name 1000.
Would you please provide guidance how to get the above expected result and thanks in advance.

Samuel

Json file:
{

Replies: 1 comment 3 replies

Comment options

You must be logged in to vote
3 replies
@sam8881998
Comment options

@chriskapp
Comment options

@sam8881998
Comment options

Answer selected by sam8881998
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants