Usually, we recommend querying the data through AX and reporting on it in an ax form or in an ssrs report. That way you don't have to deal with the details of the sql table relationships. However there are some scenarios, like building or customizing analysis services databases, where you have to connect to sql to get the data.
Generally when trying to link AX table in a sql query, you want to look at both tables to see if either of them has a relation to the other. Link up the fields in the relationship that Adam found above. In addition, whenever a table has the property SavePerCompany set to Yes, which is the case for these two tables, include the dataareaid columns from both tables in your join. If you have more than one ax data partition created, then you would need to also join the two table's partition fields.
In cases where there are multiple partition, filter by the partition value so that you aren't returning data from any other data partition than the one for which you want to report on. The partition feature isn't that much though, so you might have only one of them. You can check this by examining the records in the partitions table. If there is only record, you can ignore the partition value.
The partition field value in the data tables is a foreign key to the partitions table and links to the recId field in the paritions table. The default partition is named 'initial'. If that's the partition being used here, then you can run the query "select RECID from partitions where PARTITIONKEY = 'initial'" to get the recId for the initial partition and then add a filter to your query to select records from your tables only when the partition value for the record matches the recId for the partition you want.
Hope this helps,
Lance.