2 weeks agoby Matthias Alfers
i want to know how i can setup my table design and it's relation. My problem is how to get the Session table connected to the software table. The session table is a simple import of a CSV file and the installer_version will look like 14.6.100, 184.108.40.206, 19.5 etc. The same is stored in software installer_version to translate the installer_version to something like: SoftwareName Windows 4.6 . So, how can i set this into eloquent relations? Any idea?
The following tables are given:
Report: id user_id title slug
Software: id name platform version installer_version
Session: id report_id installer_version
Thanks for coming back to me, with your suggestion.
I thought like this:
The table Session will be just filled by importing a CSV with one Column. This Installer_version value is equal to a value in Software table. Adding a field software_id as foreign key to the session table, this has to be filled during the import of the CSV file while checking after every imported row, installer_version against software table installer_version and if matching, get the id of software and put it into sessions table software_id.