SQL to populate a hyperlink column in MS Access

前端 未结 2 622
离开以前
离开以前 2021-01-22 03:26

I imagine the SQL must pass 2 values, the value shown in the table and the link to which that value navigates.

I\'d appreciate a pointer to the SQL Script for achieving

2条回答
  •  天命终不由人
    2021-01-22 04:00

    If you're looking for a query to extract the Description and Address from a hyperlink field, try this:

    SELECT
        hlink,
        Left(hlink,InStr(1,hlink,"#")-1) AS link_description,
        Mid(hlink,InStr(1,hlink,"#")+1,InStr(InStr(1,hlink,"#")+1,hlink,"#")-InStr(1,hlink,"#")-1) AS link_address
    FROM tblHyperlink;
    

    It's sure not pretty. And it will return #Error for hyperlink fields which are Null or contain less than two # characters.

提交回复
热议问题