The words function is your friend here. Use the dash and space as delimiters and you can extract what you want easily. Here's an example that uses formulas in a table:
dt = New Table( "Untitled", Add Rows( 4 ),
New Column( "dx1", Character, "Nominal",
Set Values( {"7812-abcdef -9", "v7892-xyz -0", "812-fghkj -0",
"17361-gf-jhyt -9"}
)
),
// Get the first word for Var1
New Column( "Var1", Character, "Nominal", Formula( Words( :dx1, "- " )[1] ) ),
// Get the second word for Var1
New Column( "Var2", Character, "Nominal", Formula( Words( :dx1, "- " )[2] ) )
);