Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialShoichi iwasaki
23,380 PointsSQL RAND() Error
I could not open index.php due to this error.
PDOException: SQLSTATE[HY000]: General error: 1 no such function: RAND in /home/treehouse/workspace/inc/functions.php:25 Stack trace: #0 /home/treehouse/workspace/inc/functions.php(25): PDO->query('SELECT media_id...') #1 /home/treehouse/workspace/index.php(19): random_catalog_array() #2 {main}
Please help this problem out.
Shoichi iwasaki
23,380 PointsThank you for the reply, Liad. I didn't check the teacher's note. I re-watched the Video several times, but I was not able to fix the error. I solved the problem. Thanks.
Liad Idan
Full Stack JavaScript Techdegree Graduate 20,279 PointsLiad Idan
Full Stack JavaScript Techdegree Graduate 20,279 PointsRAND() is a mysql function and in this course we work with sqlite so you need to use RANDOM()