Vlookup function similar like Excel

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Kuttyrowdy
    New Member
    • Oct 2014
    • 1

    Vlookup function similar like Excel

    I need to do the smilar vlookup (Excel function) in SQL command.
    Just explain to the below example

    Table 1
    Store Type Region
    AA12 RGS AAA
    AA13 REM BBB
    AA14 RBK CCC

    Table 2
    Store Type Turnover
    AA12 2345
    AA13 7825
    AA14 8306

    From Table1, I need to take Type column on the basis of Store column and need to paste in Table2 with respective to the Store in table2. Same as excel vlookup function, but I need to do this by using SQL command
  • Rabbit
    Recognized Expert MVP
    • Jan 2007
    • 12517

    #2
    There's no need to store data twice. Please read our article on normalization to find out why: http://bytes.com/topic/access/insigh...ble-structures.

    If you ever need to view the data together, you just need to JOIN the two tables on the key field. If you don't know what this means, please read through this SQL tutorial here: http://www.w3schools.com/sql/.

    Comment

    Working...