asked 220k views
2 votes
What data types would you assign to the City and Zip fields when creating the Zips table?

a. TEXT to City and SHORT to Zip b. LONGTEXT to City and TEXT to Zip c. TEXT to City and TEXT to Zip d. SHORT to City and SHORT to Zip

1 Answer

2 votes

Based on common conventions and assumptions about city names and ZIP codes, a reasonable choice would be: c. TEXT to City and TEXT to Zip

The appropriate data types for the City and Zip fields in a database table depend on the specific requirements and characteristics of the data. However, based on common conventions and assumptions about city names and ZIP codes, a reasonable choice would be: c. TEXT to City and TEXT to Zip

Using TEXT for both City and Zip fields allows for flexibility in accommodating various city names and ZIP code formats. City names can vary in length, and ZIP codes may include both numerical and alphanumeric characters. TEXT is a generic data type that can handle a wide range of characters, making it suitable for these types of data.

answered
User Bobbogo
by
8.1k points