extreme help with query of 2 tables into 1 long table



2 tables user id is key

Table (A) 05_Users
user_id | first_name |last_name|title|dept
64|John|Doe|director|cis
65|Jane|Doe|ceo|fina
and

Table(B) 05_Users_Details
user_id | detail_cd | group_cd | detail_value
64|06|awdM0|null
64|07|awdD0|null
64|2005|awdY0|null
64|FreeText|awdTxt0|I enjoy work
64|10|awdM1|null
64|09|awdD1|null
64|2004|awdY1|null
64|FreeText|awdTxt1|still here
64|local|pfmLEVL1|null
64|natial|pfmLEVL1|null
64|aapm|pfmAAPM1|null
64|FreeText|pfmFREE1|profess
65|etc


I'm trying to creat a query that will give me all user information into one
long table with the group_cd as a 'column title' and detail_cd as 'column
value', but if it finds the 'column value' of FreeText then detail_value
should be 'column value'.
So the table would look like this.

user_id | first_name
|last_name|title|dept|awdM0|awdD0|awdY0|awdTxt0|awdM1|awdD1|awdY1|awdTxt1|pfmLEVL1|pfmLEVL1|pfmAAPM1|FREE TEXT
64|John|Doe|director|cis|06|07|2005|I enjoy work|10|09|2004|still
here|local|natial|aapm|profess
65|Jane|Doe|ceo|fina etc


Some users have more information than other users and in these cases the
'column value' can be left as blank.
I don't need a webpage, but if it will help, will use.
IF YOU HAVE A BETTER WAY TO GET ALL THE INFORMATION ANY SUGGESTIONS WOULD BE
GREAT!
.



Relevant Pages

  • Re: Ignored words problem
    ... both freetext and freetexttable can also generate error "A ... clause of the query contained only ignored words". ... >> avoid it either via removing noise words from the specific language ... >> 9952 This is sample text data for Scootney Books, ...
    (microsoft.public.sqlserver.fulltext)
  • Re: Exact phrase search
    ... FREETEXT that WSS uses. ... substitute CONTAINS for FREETEXT in your SQL FTS Query. ... query with an exact phrase search using the Pubs database and pub_info ...
    (microsoft.public.sqlserver.fulltext)
  • Re: Identifying fields out of order
    ... Click on "Create Query in Design View" ... tblSeq AS Prev, tblSeq AS Next; ... Our SQL now would look like: ...
    (microsoft.public.access.queries)
  • Re: FullText searching multiple tables
    ... No, you use CONTAINS, CONTAINSTABLE, or FREETEXT, FREETEXTTBLE. ... all FT enable columns in the FTS predicate queries. ... depending upon the size of your FT Catalog (based upon the number of rows in ... FTS query performance may be affected. ...
    (microsoft.public.sqlserver.programming)
  • Re: Multiple field query
    ... > I need a query that will give me single column list produced from all 20 ... > the opeation fields. ... EdS ... Prev by Date: ...
    (microsoft.public.access.queries)