Database Reference
In-Depth Information
5
Tables & Data
In this chapter, we will cover the following:
F Choosing good names for database objects
F Handling objects with quoted names
F Enforcing same name, same definition for columns
F Identifying and removing duplicate rows
F Preventing duplicate rows
F Finding a unique key for a set of data
F Generating test data
F Randomly sampling data
F Loading data from a spreadsheet
F Loading data from flat files
Introduction
This chapter covers a range of general recipes for your tables and working with the data they
contain. Many of the recipes contain general advice, though with specific PostgreSQL examples.
Some system administrators I've met work only on the external aspects of the database
server. What's actually in the database is someone else's problem.
Look after your data, and your database will look after you. Keep your data clean, and your
queries will run faster, cause less application errors, and you'll gain many friends in the
business. Getting called in the middle of the night to fix data problems just isn't cool.
Search WWH ::




Custom Search