SQL statements: Right to access

Individuals have the right to ask whether your company holds any personal data that pertains to them. You are obligated to reply and to provide that information upon request. The following table lists personal data that is stored in HCL Commerce and shows how to retrieve the data by using an SQL query.
Type of personal data Retrieval query and database table
Address
SELECT ADDRESS1, ADDRESS2, ADDRESS3, CITY, STATE, COUNTRY, ZIPCODE, OFFICEADDRESS, SELFADDRESS FROM ADDRESS WHERE MEMBER_ID=?; 
Birth date
SELECT AGE, DATEOFBIRTH FROM USERDEMO WHERE USERS_ID = ?; 
Browsing Behavior
SELECT FROM DMUSERBHVR WHERE DMUSERBHVR.PERSONALIZATIONID IN (?PERSONALIZATIONID?)
Challenge answer
SELECT CHALLENGEQUESTION, CHALLENGEANSWER FROM USERREG WHERE USERS_ID = ?;
Currency
SELECT SETCCURR FROM USERS WHERE USERS_ID = ?;
Demographics
SELECT AGE, MARITALSTATUS, CHILDREN, HOUSEHOLD, COMPANYNAME, HOBBIES FROM USERDEMO WHERE USERS_ID = ?;
Email Address or IBMid
SELECT EMAIL1, EMAIL2 FROM ADDRESS WHERE MEMBER_ID=?;
Gender
SELECT GENDER FROM USERDEMO WHERE USERS_ID = ?;
Income
SELECT INCOME FROM USERDEMO WHERE USERS_ID = ?;
Language
SELECT LANGUAGE_ID FROM USERS WHERE USERS_ID = ?;
Logon ID
SELECT LOGONID FROM USERREG WHERE USERS_ID = ?; 
Name
SELECT LASTNAME, FIRSTNAME, MIDDLENAME,NICKNAME FROM ADDRESS WHERE MEMBER_ID=?;
Order History
SELECT TOTALPRODUCT, TOTALSHIPPING, DESCRIPTION, STOREENT_ID, CURRENCY, TIMEPLACED, LASTUPDATE FROM ORDERS WHERE MEMBER_ID =?;
Password (for shoppers and CSRs)
SELECT LOGONPASSWORD FROM USERREG WHERE USERS_ID = ?;
Phone Number
SELECT PHONE1, FAX1, FAX2, PHONE2, PUBLISHPHONE1, PUBLISHPHONE2, MOBILEPHONE1 FROM ADDRESS WHERE MEMBER_ID=?; 
Referral URL
SELECT FROM DMUSERBHVR WHERE DMUSERBHVR.PERSONALIZATIONID IN (?PERSONALIZATIONID?)
Search History
SELECT FROM DMUSERBHVR WHERE DMUSERBHVR.PERSONALIZATIONID IN (?PERSONALIZATIONID?)