1

I am wondering what the proper name is for an array held in a string (string that holds an array).

Commonly used for storing tags or multiple variables in a database

EXAMPLE 1 (Image URLs for item): url1,url2,url3

Example 2 (Video Tags): tag1,tag2,tag3

Example 3 (quests complete): 2,3,1,6,7,4

These strings would get converted into an array with an explode in PHP usually.

To clarify: What is the proper name for these types of strings?

Liam Pillay
  • 592
  • 1
  • 4
  • 19

1 Answers1

1

These values are stored as comma separated values or CSV. This is a relatively common practice as a way to store multiple data points uder a single entry.

From wikipedia

A comma-separated values (CSV) file is a delimited text file that uses a comma to separate values. A CSV file stores tabular data (numbers and text) in plain text. Each line of the file is a data record. Each record consists of one or more fields, separated by commas. The use of the comma as a field separator is the source of the name for this file format.

Hope this helps,

Miroslav Glamuzina
  • 4,472
  • 2
  • 19
  • 33
  • Except that I doubt OP applies actual CSV rules, like using quotes if values contain commas… – deceze Oct 15 '19 at 07:16